|
Integration
Can I integrate Gawab Email Application into my web site ?
Sure, you can easily do that so that your users will not feel that they have left your web site.
Is that difficult ?
No, you will just need to add a few lines of code to your web site.
To do this you can embed the login form on your site as follows:
- Create an html page for the user to log-in.
- This page must contain a form tag with the following input names:
- "logindomain" : this must hold your site domain name with type "hidden".
- method "post" and action "http://www.gawab.com/cgi-bin/gawabcli".
as an example:
<html>
<head>
<script language="javascript">
function checkForm(form)
{
var validated = true;
if(form.username.value == "")
{
validated = false;
alert("Please enter your name.");
form.username.focus();
}
else if(form.password.value == "")
{
validated = false;
alert("Please enter your password.");
form.password.focus();
}
else validated=true;
return validated;
}
function getError()
{
srch = location.href;
if(srch.indexOf('gawaberr=1')>0)
alert('Invalid Login, Please check your user name and password');
}
</script>
</head>
<body onload="getError()">
<form method="post" action="http://www.gawab.com/cgi-bin/gawabcli" onsubmit="return checkForm(this)">
<input type="text" name="username" >
<input type="password" name="password" >
<input type="hidden" name="logindomain" value="YOURDOMAIN.COM">
<input type="submit" Value ="login">
</form>
</body>
</html>
- For English registration make a HyperLink to the following URL:
http://www.gawab.com/register.html?lng=en&privatedomain=YOURDOMAIN.COM
- For Arabic registration make a HyperLink to the following URL:
http://www.gawab.com/register.html?lng=ar&privatedomain=YOURDOMAIN.COM
- For English Forgot your Passward make a HyperLink to the following URL:
http://www.gawab.com/forgotpass.html?lng=en&domain=YOURDOMAIN.COM
- For Arabic Forgot your Passward make a HyperLink to the following URL:
http://www.gawab.com/forgotpass.html?lng=ar&domain=YOURDOMAIN.COM
- Then all you have to do is to enter the full URL of this html page in the login page location.
You can even make use of the error codes returned by Gawab in case of invalid username or password and customize your own responses to such errors.
© Copyright 2000 Gawab.com, Inc. - All rights reserved.
|