Could any one tell me a simple example where a user is presented with a login page(login.html), enters his username and password, the login details are used to call a webservice using AJAX POST and once username is retrieved, I need to redirect it to another page (home.html). So basically all this is happening using HTML and Javascript and no server side language involved here.
Here is the simple login form I have:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"><html>
<head>
<title>Accounting</title>
<style type="text/css">
html,body{height: 100%; padding:0; margin:0;}
form{ width:30em;height:9em; margin:-5em auto 0 auto; position: relative; top:50%; border:1px dotted #ccc; padding:.25em; }
fieldset{ margin:0; border:0;padding:0;}
legend{float:left; font-size: 200%; text-align: center; color:blue; font-weight: bold; border-bottom: 1px solid blue; width:15em; padding:0; }
label, label+ input {display:inline; float:left;margin-top:1em;}
label{text-align: right; width:28%; clear: left; margin-top:.8em; }
label+ input{ width:60%; padding:.25em; ; margin-left:.5em; border: 1px inset; margin-left: }
#sub{ margin-top:1em; position: relative; float:left;clear: left; margin-left: 29%}
</style>
</head>
<body>
<form >
<fieldset><legend>User Login Page</legend>
<label for="name">UserName: </label><input type="text" name="name" id="name" value="">
<label for="password">Password: </label><input type="password" name="password" id="password" >
<input type="submit" value="Login" id="sub">
</fieldset>
</form>
</body>
</html>