mirror of
https://github.com/timmypidashev/web.git
synced 2026-04-14 19:13:51 +00:00
push more code
This commit is contained in:
1
editor.html
Normal file
1
editor.html
Normal file
@@ -0,0 +1 @@
|
|||||||
|
hi
|
||||||
@@ -1,6 +1,15 @@
|
|||||||
$("#login-button").click(function(event){
|
// Below function Executes on click of login button.
|
||||||
event.preventDefault();
|
function validate(){
|
||||||
|
var username = document.getElementById("username").value;
|
||||||
$('form').fadeOut(500);
|
var password = document.getElementById("password").value;
|
||||||
$('.wrapper').addClass('form-success');
|
if ( username == "student" && password == "student.23264"){
|
||||||
});
|
// window.location = "editor.html"; // Redirecting to other page.
|
||||||
|
// properly redirect to editor.html
|
||||||
|
window.location.replace("https://timmypidashev.com/editor.html");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
alert("Username/Password is incorrect");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -12,9 +12,9 @@
|
|||||||
<h1>Login</h1>
|
<h1>Login</h1>
|
||||||
|
|
||||||
<form class="form">
|
<form class="form">
|
||||||
<input type="text" placeholder="Username">
|
<input id="username" type="text" placeholder="Username">
|
||||||
<input type="password" placeholder="Password">
|
<input id="password" type="password" placeholder="Password">
|
||||||
<button type="submit" id="login-button">Login</button>
|
<button type="submit" id="login-button" onclick="validate()">Login</button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -33,3 +33,5 @@
|
|||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
<script src="js/less.js" data-env="production"></script>
|
<script src="js/less.js" data-env="production"></script>
|
||||||
|
<!-- add login function -->
|
||||||
|
<script src="js/python/login.js"></script>
|
||||||
Reference in New Issue
Block a user