PDA

View Full Version : Edititng form fields and validated entries


alejandro39255
05-19-2009, 02:35 PM
Hi:

I have a form with many fields that I'm filling out using a recordset, the problem I'm having with the validation toolkit is that when I use the validated entries for the initial values of my fields and run the page my data is lost, I have to type all over again for the validation toolkit save the values.

Any help would be much appreciated.

Ray Borduin
05-19-2009, 05:05 PM
Pass a url parameter in your failed redirect for your server validations like: pagename?valid=false

Then for your initial value instead of setting it to: <?php echo(ValidatedField("page","field")); ?>

set it to something like:
<?php echo(isset($_GET['valid'])?ValidatedField("page","field"):"yourdefault"); ?>

This way if the page was just validated and failed it shows the validated value as you want, but if not, the url parameter is not there and it shows the default value instead.

alejandro39255
05-19-2009, 09:55 PM
Thanks Ray I'll try that and let you know the outcome.

thank you for your time.

Alejandro