From 3c4689fce2bd493f35516ebf0c247fa1a31f866b Mon Sep 17 00:00:00 2001 From: Carles Tubio Date: Sat, 9 Jan 2016 23:37:42 +0000 Subject: [PATCH 1/2] Show error message in red, only once, and inside the correct form. --- pool/page_reg.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pool/page_reg.php b/pool/page_reg.php index f9c01d04..3728661d 100644 --- a/pool/page_reg.php +++ b/pool/page_reg.php @@ -34,8 +34,8 @@ Your miner password should be 'x' and must not use your login pass $pg .= '
'; $pg .= '

Login

'; - if (isset($data['data']['error'])) - $pg .= "
".$data['data']['error']." - please try again

"; + if (isset($data['data']['error']) && !isset($_POST['pass2'])) + $pg .= "
".$data['data']['error']." - please try again

"; $pg .= makeForm(''); $pg .= " @@ -55,8 +55,8 @@ Your miner password should be 'x' and must not use your login pass $pg.= '
'; $pg .= '

Register

'; - if (isset($data['data']['error'])) - $pg .= "
".$data['data']['error']." - please try again

"; + if (isset($data['data']['error']) && isset($_POST['pass2'])) + $pg .= "
".$data['data']['error']." - please try again

"; $pg .= makeForm(''); $pg .= " From e4b94930375af20b244fca1fb5fd80291a64456e Mon Sep 17 00:00:00 2001 From: Carles Tubio Date: Sun, 24 Jan 2016 23:32:15 +0000 Subject: [PATCH 2/2] Fixed style in error msg --- pool/page_reg.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pool/page_reg.php b/pool/page_reg.php index 3728661d..5b50894f 100644 --- a/pool/page_reg.php +++ b/pool/page_reg.php @@ -35,7 +35,7 @@ Your miner password should be 'x' and must not use your login pass $pg .= '

Login

'; if (isset($data['data']['error']) && !isset($_POST['pass2'])) - $pg .= "
".$data['data']['error']." - please try again

"; + $pg .= "
".$data['data']['error']." - please try again

"; $pg .= makeForm(''); $pg .= "
@@ -56,7 +56,7 @@ Your miner password should be 'x' and must not use your login pass $pg .= '

Register

'; if (isset($data['data']['error']) && isset($_POST['pass2'])) - $pg .= "
".$data['data']['error']." - please try again

"; + $pg .= "
".$data['data']['error']." - please try again

"; $pg .= makeForm(''); $pg .= "