Angelo Zanetti wrote:

-----Original Message-----
From: aditya shukla [] Sent: 11 January 2010 07:37 AM
To: php-general
Subject: [PHP] Form validation and save the form

Hello Guys,

I am trying to validate a form for user input , such that when something is
missing load the form again by focusing on the  wrong field.Say i don not
enter my address so when the form loads everything else is saved and the
form points to address field.



You need Javascript for that not PHP. PHP is server side, javascript is
client side (browser).

He doesn't say anything about not reloading the form... in fact he explicitly says "when something is missing load the form again". This suggests a server request and not JavaScript. Either way... validation can occur either in JavaScript or PHP... but it should ALWAYS occur in PHP regardless of any JavaScript validation.

Application and Templating Framework for PHP

PHP General Mailing List (
To unsubscribe, visit:

Reply via email to