PDA

View Full Version : A basic login, pretty please :(



elliot
05-11-2006, 10:05 PM
Hi there,

I'm not in good shape here, hopefully you can help... all I want is a basic login page.

I found a script which I've uploaded, which works though how do I tell it to go to the next page?

basically I'd like to have page A (with the script below, or whatever script) to go to page B with the members page

http://www.bhbgroup.co.uk/includelogin.asp

thank you very much

Twey
05-11-2006, 10:06 PM
http://www.asp101.com/samples/login.asp

elliot
05-11-2006, 11:05 PM
I'm very sorry I find this so bl**dy hard :( though even the most basic is doing my head in. I've been to loads of different sites to try and work through their versions...

Where I've started to try a get a login page working I've also tried this page to see if I get any results

http://www.bhbgroup.co.uk/contact_test1.html

I'm getting this message

Microsoft VBScript runtime error '800a0046'

Permission denied

/contactusprocess.asp, line 36

Have I got to set something up on the server? though I did do a test with a date script earlier that worked :confused:

After I've got this sorted I'm sticking to design I think!

MuffinMan
05-12-2006, 06:03 PM
If you're looking for a real simple login page, here's some code that I use on our internal website all the time. Change the yourusername, yourpassword, and the www.theurlyouwantogoto.com variables to suit your own code. I hope it will help you.



<script language="javascript">
<!--//
/*This Script allows people to enter by using a form that asks for a
UserID and Password*/
function pasuser(form) {
if (form.id.value=="yourusername") {
if (form.pass.value=="yourpassword") {
location="http://www.theurlyouwanttogoto.com"
} else {
alert("Invalid Password")
}
} else { alert("Invalid UserID")
}
}
//-->
</script>

<center>
<table bgcolor="white" cellpadding="12" border="1" width="410" height="212">
<tr><td colspan="2" width="378" height="45"><center><h1><b><font size="5">Associate Satisfaction Survey</font><i><br>
<font size="3">Access allowed for designated departments only</font></i></b></h1></center></td></tr>
<tr><td width="163" height="12"><h1><i><b><font size="4">User ID:</font></b></i></h1></td><td width="187" height="12"><form name="login"><input
name="id" type="text"></td></tr>
<tr><td width="163" height="11"><h1><i><b><font size="4">Password:</font></b></i></h1></td><td width="187" height="11"><input name="pass"
type="password"></td></tr>
<tr><td width="163" height="32"><center><input type="button" value="Login"
onClick="pasuser(this.form)"></center></td><td width="187" height="32"><center><br><input
type="Reset"></form></td></tr></table></center>
<p align="center"><font size="3">The following departments have been selected to
participate in this survey:</font></p>
<div align="center">
<center>
<table border="0" cellspacing="1" width="282">
<tr>
<td width="145" align="left"><font size="3">ASC</font></td>
<td width="123" align="left"><font size="3">Hospice</font></td>
</tr>
<tr>
<td width="145" align="left"><font size="3">Emergency Dept.</font></td>
<td width="123" align="left">
<p align="left"><font size="3">Maintenance</font></td>
</tr>
<tr>
<td width="145" align="left"><font size="3">Food Services</font></td>
<td width="123" align="left"><font size="3">Medical Records</font></td>
</tr>
<tr>
<td width="145" align="left"><font size="3">Home Health</font></td>
<td width="123" align="left"></td>
</tr>
</table>
</center>
</div>
<p align="center"><font size="3">Please see your department director for the
User ID and Password</font></p>
<p align="center"><font color="#FF0000">The <b> first</b> department reaching 100% participation each quarter will receive Chamber of Commerce Gift Certificates for each associate. The remaining departments within the group that reach 100% participation will receive a pizza party</font></p>

elliot
05-12-2006, 08:43 PM
Many thanks MuffinMan, I've gone and added that in place which will do nicely
http://www.bhbgroup.co.uk/client.html

It doesn't need to be overly sercure only holding a form on the other side for clients to submit orders. They'll need a product code via email to use on the order form so this is more than adequate.

cheers mate!