JOE
2018-10-29 872ceef23617d9fb6914c5cbfd3cf4bb77f14fb2
commit | author | age
b09781 1 <!DOCTYPE html>
J 2 <html>
3 <head>
4     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
5     <meta charset="utf-8">
6     <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
7cce65 7     <title>MOBITHRU</title>
b09781 8     <link href="{{cdnRoot}}/css/login.css" rel="stylesheet">
J 9
10     <!-- Scripts -->
11     <script src="{{cdnRoot}}/jquery-plugins/jquery-3.3.1.min.js"></script>
12     <script src="{{cdnRoot}}/js/amm-config.js" defer></script>
13     <style>
14         .email-input.error, .email-input.error:focus {
15             border: 1px solid #ed1c24;
16         }
17         .email-input.error::placeholder {
18             color: #ed1c24;
19         }
20     </style>
21 </head>
22 <body>
23 <div class="lcell">
24     <div class="logo-bg">
25         <span class="logo-image"></span>
26     </div>
27     <div class="title-login">
28         Log In
29     </div>
872cee 30     <form class="login-account" action="{{context}}/login" method="post" accept-charset="utf-8">
b09781 31         <div class="input-form">
J 32             <span class="label">E-mail address</span>
5ea03c 33             <input class="email-input" type="text" name="login_id" id="login_id" placeholder="E-mail address" autocomplete="on" tabindex="1" value="{{email}}">
b09781 34             <div class="password">
J 35                 <span class="label">Password</span>
36                 <a class="forgot-password" href="#" tabindex="3">Forgot Password?</a>
37             </div>
38
39             <input class="password-input" type="password" name="password" id="password" placeholder="Password" autocomplete="off" tabindex="2">
40         </div>
872cee 41         <button class="btn-login" type="submit" name="login-btn" formaction="{{context}}/login">Log In</button>
b09781 42     </form>
J 43     <div class="divider-login-lcell"></div>
44
872cee 45     <a href="{{context}}/signup" class="btn-create-account" tabindex="4">Create Account</a>
b09781 46 </div>
J 47
48 <div class="rcell">
49     <img class="rcell-img" src="{{cdnRoot}}/img/login-rcell.png" alt="">
50     <a href="http://www.mobithru.com" class="find-out-more" type="text" name="find-out-more" tabindex="5">Find out more</a>
51 </div>
52 <div class="universial-footer">
53     <span>&#169;2018 accessmotion Co.,Ltd. All rights reservedaaaaaaaa.</span>
54 </div>
55 <script>
56     $(document).ready(function () {
5ea03c 57         $('input[name="login_id"]').focus();
b09781 58
J 59         $('form').submit(function() {
5ea03c 60             if($('#login_id').val() == '') {
J 61                 $('input[name="login_id"]').addClass('error').attr('placeholder', 'Please, enter your email.');
b09781 62                 return false;
J 63             }else if($('#password').val() == '') {
5ea03c 64                 $('input[name="login_id"]').removeClass('error').attr('placeholder', 'E-mail address');
b09781 65                 $('input[name="password"]').addClass('error').attr('placeholder', 'Please, enter your password.');
J 66                 return false;
67             } else {
68                 return true; 
69             }
70         });
71
72         {{#invalidUser}}
5ea03c 73         $('input[name="login_id"]').addClass('error').attr('placeholder', 'Email is invalid.');
b09781 74         {{/invalidUser}}
J 75         {{#invalidPasswd}}
76         $('input[name="password"]').addClass('error').attr('placeholder', 'Password is invalid.');
77         {{/invalidPasswd}}
5ea03c 78         {{#invalidTokken}}
J 79             alert('Failed make a token. Please ask our support team.');
80         {{/invalidTokken}}
81
b09781 82     });
J 83 </script>
84 </body>
85 </html>