diff options
| author | oweissbarth | 2014-03-11 20:02:10 +0100 |
|---|---|---|
| committer | oweissbarth | 2014-03-11 20:02:10 +0100 |
| commit | a9d708cf9638686d81caf2cc9534a5d34dd63b7e (patch) | |
| tree | 67abfa3c17aa534c638bc6431263a01ce99be3ec | |
| parent | ed809aa402ef6b97a129f06d2ba2e7a97101291f (diff) | |
| download | files.iamfabulous.de-a9d708cf9638686d81caf2cc9534a5d34dd63b7e.tar.gz | |
Added errors for register-form. Gave errors more room
| -rw-r--r-- | www/login.php | 4 | ||||
| -rw-r--r-- | www/register.php | 15 | ||||
| -rw-r--r-- | www/static/login.css | 15 | ||||
| -rw-r--r-- | www/static/register.css | 42 |
4 files changed, 63 insertions, 13 deletions
diff --git a/www/login.php b/www/login.php index df50166..f0afaf5 100644 --- a/www/login.php +++ b/www/login.php @@ -17,8 +17,8 @@ <link rel="stylesheet" type="text/css" href="static/login.css"> <div class="login-area"> - <div class="login-area" id="login-top-bar"> - <h1 class="login-area"> Log in </h1> + <h1 class="login-area"> Log in </h1> + <div class="login-area" id="login-info-bar"> <?php if(isset($_GET['reason']) && $_GET['reason'] == 'failure' && isset($_GET['username'])){ echo '<h1 id="login-error"> Invalid username or password </h1> '; diff --git a/www/register.php b/www/register.php index daf6afa..e4c4b79 100644 --- a/www/register.php +++ b/www/register.php @@ -19,6 +19,21 @@ <div class="register-area"> <h1 class="register-area"> Register </h1> + <div class="register-area" id="register-info-bar"> + <?php if(isset($_GET['reason']) && $_GET['reason'] == 'password'){ + echo '<h1 id="register-error">Passwords don't match</h1> + '; + }elseif(isset($_GET['reason']) && $_GET['reason'] == 'encoding'){ + echo '<h1 id="register-error">The password contains unsupported characters</h1> + '; + }elseif(isset($_GET['reason']) && $_GET['reason'] == 'database'){ + echo '<h1 id="register-error"> Internal Error. Please contact admin</h1> + '; + }elseif(isset($_GET['reason']) && $_GET['reason'] == 'prohibited'){ + echo '<h1 id="register-error">Activation of your account is prohibited</h1> + '; + }?> + </div> <form id="register-form" action="/register" method='post'> <input type="text" placeholder="username" name="username" id="username-input" class="register-input" required> diff --git a/www/static/login.css b/www/static/login.css index 0ed0dea..6697bcc 100644 --- a/www/static/login.css +++ b/www/static/login.css @@ -2,21 +2,28 @@ Login-Form **********************************************************/ div.login-area{ - height: 200px; + height: 230px; width: 400px; position: relative; top: 50%; - margin-top: -100px; + margin-top: -115px; margin-left: auto; margin-right: auto; border: 1px solid #1F3D4C; padding: 10px; +} +h1.login-area{ + font-size: 32px; + font-weight: normal; + line-height: 32px; + padding:0; + display: block; } -#login-top-bar{ +#login-info-bar{ display: block; - width: 395px; + width: 400px; height:32px; padding:0; margin:0; diff --git a/www/static/register.css b/www/static/register.css index ffd425b..40034d2 100644 --- a/www/static/register.css +++ b/www/static/register.css @@ -2,24 +2,52 @@ Register-Form **********************************************************/ div.register-area{ - height: 370px; + height: 400px; width: 400px; position: relative; top: 50%; - /*transform: translateY(-50%); - -ms-transform: translateY(-50%); - -webkit-transform: translateY(-50%);*/ - margin-top: -185px; - + margin-top: -200px; margin-left: auto; margin-right: auto; - vertical-align: middle; border: 1px solid #1F3D4C; padding: 10px; } h1.register-area{ + font-size: 32px; font-weight: normal; + line-height: 32px; + padding:0; + display: block; +} + +#register-info-bar{ + display: block; + width: 400px; + height:32px; + padding:0; + margin:0; + position: static; + border: none; +/* border: 1px solid blue;*/ +} + +#register-error{ + font-size: 13pt; + background: red; + text-align:right; + float:right; + line-height: 26px; + border: 3px solid #1F3D4C; +} + +#logout-message{ + font-size: 13pt; + text-align:right; + float:right; + display: inline-block; + line-height: 26px; + border: 3px solid #1F3D4C; } form.register-form{ |
