We use cookies to provide you with a better experience. If you continue to use this site, we'll assume you're happy with this. Alternatively, click here to find out how to manage these cookies

hide cookie message
Contact Forum Editor

Send an email to our Forum Editor:


PLEASE NOTE: Your name is used only to let the Forum Editor know who sent the message. Both your name and email address will not be used for any other purpose.

Tech Helproom


It's free to register, to post a question or to start / join a discussion


 

Making form fields required when validating


lonemascot

Likes # 0

I have a form which I have made using DW CS4. I also have a standard PHP script which I got off the internet. click here for a link to another post with the PHP script I used.

I have put this form on my server for testing click here. please be aware it is not finished and is why it looks as such.

I have 3 problems so far.

1) The list menu that has the title fields in it will allow the form to be submitted even if the 'please select...' field is highlighted. How do i make that field an invalid entry?

2) If a value is inputted into the 'side measurement' field then I want to make sure that a selection has to be made from the 'edge' list menu. How do I do an 'if not blank then require selection' command for validation?

3) I want users to tick a checkbox stating that they agree to my T&C's. At the moment the form can be submitted even if the checkbox is left unticked. I can just say 'if you click submit you agree to my T&C's' but I would like to have the user actively click an agreement. Plus I'd be interested in knowing how it was done anyway.

I have used spry validation on these relevant fields and have added a 'validate form' behavior. Obviously, I'm missing something and I need help. I'm not a web designer by trade, I'm a builder so forgive me if its an obvious fix.

Thanks

Like this post
lonemascot

Likes # 0

ideas?

Like this post

Reply to this topic

This thread has been locked.



IDG UK Sites

Microsoft Band UK release date and price rumours, features and specs: Microsoft smartwatch unveiled

IDG UK Sites

Why Sony's PS4 2.0 update is every gamer's dream (well, mine at least)

IDG UK Sites

This Grolsch ad combines stop-motion & CG for majestic results

IDG UK Sites

Apple rumours and predictions for 2015: What to expect from Apple in 2015