From 3c4689fce2bd493f35516ebf0c247fa1a31f866b Mon Sep 17 00:00:00 2001 From: Carles Tubio Date: Sat, 9 Jan 2016 23:37:42 +0000 Subject: [PATCH] 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 .= "