mirror of
https://github.com/shouptech/tempgopher.git
synced 2026-02-03 08:39:43 +00:00
Make enter on the login page do things
This commit is contained in:
parent
5fd5acc0cc
commit
595751d5d4
2 changed files with 14 additions and 19 deletions
|
|
@ -6,12 +6,5 @@ function processLogin() {
|
|||
window.location.replace(jsconfig.baseurl + "/app/");
|
||||
};
|
||||
|
||||
function addClickToLogin() {
|
||||
$("#loginButton").click(processLogin);
|
||||
};
|
||||
|
||||
// If the login page is displayed, we need to remvoe any existing auth tokens
|
||||
window.localStorage.removeItem("authtoken");
|
||||
|
||||
// Set the click function for the login button
|
||||
$(document).ready(addClickToLogin);
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@
|
|||
<div class="four columns offset-by-four"><h3 style="text-align: center">Login</h3></div>
|
||||
</div>
|
||||
</div>
|
||||
<form onsubmit="processLogin(); return false;">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="two columns offset-by-two" style="text-align: right">Username:</div>
|
||||
|
|
@ -31,5 +32,6 @@
|
|||
<div class="four columns offset-by-four"><button type="submit" id="loginButton" style="width: 100%" class="button button-primary">Login</button></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue