Am Newbie here.Am Beginner in php.I Create a sample Reg form.Here i want to Validate My all Fields is Not equal to Empty like that. i have text field,check box,Radio button,Select box & Email field.
Please tell with Example.Thanks in Advance.
Am Newbie here.Am Beginner in php.I Create a sample Reg form.Here i want to
Share
This should work for checking empty values. Just add the keys of the required fields in your form to the required array. The $$key = $value creates a variable with the same name as the key and puts the value in their for you. So if your fields were “Name” and “Email” after the loop you could access the variables $Name and $Email with the correct values in.
You may want to check and display the errors afterwards like so