RE: [PHP] Form validation of dynamically generated forms?
| From: | Grant Walters | Date: | Mon, 28 Aug 2000 21:30:30 +0000 |
| Subject: | RE: [PHP] Form validation of dynamically generated forms? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-14011@lists.php.net to get a copy of this message | ||
I'm not a Javascript programmer by any means but have you tried referencing
variables like this:
document.myForm.['QUANTITY1'].value
> echo "\t\tif (document.myForm.QUANTITY$x.value == '') {\n";
> > echo "\t\t\talert(\"You must enter a value for the Quantity
> > field.\")\n";
> > echo "\t\t\tdocument.myForm.QUANTITY$x.focus();\n";
> > echo "\t\t\treturn (false);\n";
> > echo "\t\t}\n";
> >
>
Regards
GRANT WALTERS
Walters & Associates, P O Box 13-043, Johnsonville, Wellington, New Zealand
Phone: +64 4 4765175 CellPhone: 025 488265