J
julietta carpentieri
I would like to know if we could modify the script below to have
different usernames and passwords which, depending on which company
they are with would take them to their company page. For example:
A person from company ABC would have a username of : XXX
and a password : 123
It would then take them to the ABC webpage created for them
(abcprograms.html)
A person from company DEF would have a username of : YYY
and a password : 456
It would then take them to the DEF webpage created for them.
(defprograms.html)
A person from company GHI would have a username of : UUU
and a password : 789
It would take them to their company webpage we created for them.
(ghiprograms.html)
I want to do this from one central login page. Would I be able to do
this with the script below, or would we need to use something else?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>Valero Login</title>
</head>
<body bgcolor="#336699">
<script language = "javascript">
/*
Script by Anubhav Misra ([email protected])
Submitted to JavaScript Kit (http://javascriptkit.com)
For this and 400+ free scripts, visit http://javascriptkit.com
*/
function validate(text1,text2,text3,text4)
{
if (text1==text2 && text3==text4)
load('programs.html');
else
{
load('failure.html');
}
}
function load(url)
{
location.href=url;
}
</script>
<table width="50%" border="0" cellspacing="0" cellpadding="4"
align="center" bgcolor="#FFFFFF">
<tr>
<td height="2" bgcolor="#333366"><font size="2" face="Verdana,
Arial, Helvetica, sans-serif" color="#FFFFFF"><b><font face="Arial,
Helvetica, sans-serif" size="3">Welcome!</font></b></font></td>
</tr>
<tr>
<td height="149"><div align="left">
<form>
<p><font color="#000000" size="2" face="Arial, Helvetica,
sans-serif">Username :</font>
<input type="text" name="text2">
</p>
<p> <font color="#000000" size="2" face="Arial, Helvetica,
sans-serif">Password :</font>
<input type="password" name="text1">
<input type="button" value="Login" name="Submit"
onClick=javascript:validate(text2.value,"Antonio",text1.value,"bluebonnet")</p>
</form>
</div></td>
</tr>
<tr>
<td height="2"><div align="left">
<table width="80%" border="0" cellspacing="0" cellpadding="0"
align="center">
<tr>
<td height="2"><div align="center"><font size="1"
face="Verdana, Arial, Helvetica, sans-serif" color="#5B7D99">If you
experience any problems with xxx.com please contact the <a
href="mailto:[email protected]">webmaster</a></font></div></td>
</tr>
<tr>
<td height="2"> </td>
</tr>
</table>
</div></td>
</tr>
</table>
</body>
</html>
I appreciate your help.
Thanks,
Julie Carpenter
different usernames and passwords which, depending on which company
they are with would take them to their company page. For example:
A person from company ABC would have a username of : XXX
and a password : 123
It would then take them to the ABC webpage created for them
(abcprograms.html)
A person from company DEF would have a username of : YYY
and a password : 456
It would then take them to the DEF webpage created for them.
(defprograms.html)
A person from company GHI would have a username of : UUU
and a password : 789
It would take them to their company webpage we created for them.
(ghiprograms.html)
I want to do this from one central login page. Would I be able to do
this with the script below, or would we need to use something else?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<title>Valero Login</title>
</head>
<body bgcolor="#336699">
<script language = "javascript">
/*
Script by Anubhav Misra ([email protected])
Submitted to JavaScript Kit (http://javascriptkit.com)
For this and 400+ free scripts, visit http://javascriptkit.com
*/
function validate(text1,text2,text3,text4)
{
if (text1==text2 && text3==text4)
load('programs.html');
else
{
load('failure.html');
}
}
function load(url)
{
location.href=url;
}
</script>
<table width="50%" border="0" cellspacing="0" cellpadding="4"
align="center" bgcolor="#FFFFFF">
<tr>
<td height="2" bgcolor="#333366"><font size="2" face="Verdana,
Arial, Helvetica, sans-serif" color="#FFFFFF"><b><font face="Arial,
Helvetica, sans-serif" size="3">Welcome!</font></b></font></td>
</tr>
<tr>
<td height="149"><div align="left">
<form>
<p><font color="#000000" size="2" face="Arial, Helvetica,
sans-serif">Username :</font>
<input type="text" name="text2">
</p>
<p> <font color="#000000" size="2" face="Arial, Helvetica,
sans-serif">Password :</font>
<input type="password" name="text1">
<input type="button" value="Login" name="Submit"
onClick=javascript:validate(text2.value,"Antonio",text1.value,"bluebonnet")</p>
</form>
</div></td>
</tr>
<tr>
<td height="2"><div align="left">
<table width="80%" border="0" cellspacing="0" cellpadding="0"
align="center">
<tr>
<td height="2"><div align="center"><font size="1"
face="Verdana, Arial, Helvetica, sans-serif" color="#5B7D99">If you
experience any problems with xxx.com please contact the <a
href="mailto:[email protected]">webmaster</a></font></div></td>
</tr>
<tr>
<td height="2"> </td>
</tr>
</table>
</div></td>
</tr>
</table>
</body>
</html>
I appreciate your help.
Thanks,
Julie Carpenter