Personal computing discussed

Moderators: renee, SecretSquirrel, just brew it!

 
5150
Minister of Gerbil Affairs
Topic Author
Posts: 2389
Joined: Wed Jun 04, 2003 6:22 pm
Location: Sales Tax Is For Commies

Easy CGI

Wed May 05, 2004 10:50 am

I have a web page where I want to have someone enter a four digit code, and then have it direct the person to a web page if they enter the correct code. Here is what I have so far:

<form method="GET">
<p>Please enter your four digit code:</p>
<p>
&<!--webbot bot="Validation" s-data-type="Number" s-number-separators="x." b-value-required="TRUE" i-minimum-length="4" i-maximum-length="4" s-validation-constraint="Greater than or equal to" s-validation-value="0629" --><input type="password" name="Code" size="4" maxlength="4"></p>
   <p><input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></p> 
</form>   
 


The problem I'm having is trying to get it to direct the customer to the page. I'm sure it's very easy, I've just been out of the programming loop for too long.

Thanks!
 
5150
Minister of Gerbil Affairs
Topic Author
Posts: 2389
Joined: Wed Jun 04, 2003 6:22 pm
Location: Sales Tax Is For Commies

Thu May 06, 2004 5:44 pm

Nevermind, I figured out how to use it with JavaScript. Thought I would post this link as it is where I found the answer.

http://javascript.internet.com/ <- The Site
http://javascript.internet.com/passwords/three-tries.html <-The Answer
 
Hawkwing74
His Holy Gerbilness
Posts: 13961
Joined: Wed Aug 20, 2003 5:51 pm
Location: Streamwood, IL

Thu May 06, 2004 5:57 pm

My html is rusty, but you don't let them look at the source, do you? Or are you showing us the code stored on the server?
 
5150
Minister of Gerbil Affairs
Topic Author
Posts: 2389
Joined: Wed Jun 04, 2003 6:22 pm
Location: Sales Tax Is For Commies

Thu May 06, 2004 7:34 pm

I actually did it with JavaScript, and yes, you can see the password in the source. I disable right clicking on that page in particular so that helps. Security really isn't a big issue as it is just a temporary thing to let only certain customers into our online store to test it. I'm not concerned if someone else goes in and orders something from us. :wink:

Who is online

Users browsing this forum: No registered users and 14 guests
GZIP: On