Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
Thread: Input validation
09-15-2008, 04:49 AM #1
- Join Date
- Sep 2008
- Thanked 0 Times in 0 Posts
I have seen something similar to this in the threads, but tried my own version and it doesn't seem to be working. I have attached my script, if I could get a little help. Thank you.
1. Create a cross-browser (works in Firefox and MS IE) input screen that takes in a client’s information for an order:
* Full Name (text field)
* Address (textarea)
* Gender (radio button)
* Date of birth (three dropdown lists – day, month, year)
* “Send me newsletter” (checkbox)
* Hidden total value for order (hidden field)
* “Submit Order” button (button).
2. When the user is done with input, validate using the rules below:
* At least 3 characters required in name
* Must be over 18 years old
* Gender must be selected
3. If validation passes, show the information in an alert box and write ‘Your order has been submitted’. Otherwise, alert the user with the appropriate validation error and set focus on the input field that failed validation.
09-16-2008, 04:21 AM #2
- Join Date
- Feb 2008
- Cebu City, Philippines
- Thanked 372 Times in 365 Posts