I am making a database and need people to enter info, buit they can submit the form and not enter the data into the fields. Is there a function that will tell the user to fill out the required fields or will it require some adlib programming?
Hi Giles,
If you assign variable names to each form element and test for the existence of that variable, you will be able to determine whether or not it has been filled out.
Use isset($varName) to test for a value.
Cheers,
David Grant
You can also use Javascript to force the user to fill out certain fields before being able to submit the form. There are many form validation scripts out there and they work very well. I would just caution the use of only the Javascript especially if you are inserting the received data into a database.
Hope this helps!
John Cornett Senior Development Engineer Web Teks, Inc. http://www.web-teks.com E-Mail: john@web-teks.com