Ok, i'm using javascript to login, heres my codes:
JavaScript:HTML Code:<div id="bth_login"> <form id="bth_login" name="bth_login" action="javascript: bthlogin();" method="post"> <p><strong>Username</strong>:<br> <input type="text" name="username" id="username" size="20"></p> <p><strong>Password</strong>:<br> <input type="password" name="password" id="password" size="20"></p> <p><input type="submit" value="Submit" name="submit"></p> </form> </div>
Should that work?HTML Code:function bthlogin() { username = document.getElementById('username').value; password = document.getElementById('password').value; $('bth_login').innerHTML = '<img src="images/loading.gif" />'; new Ajax.Request('login.php', { parameters: {username: username, password: password}, onSuccess: function(send) { $('bth_login').innerHTML = send.responseText; } }); }





Reply With Quote




