Problem with Initial Value on form Fields when page returns validation error
I am using the Form Toolkit and Universal E-mail 4 in DW CS5, although this seems to be a problem just with the Form Toolkit. I have added initial values to all the form fields on my webform to be dynamic using the form field. This is some example code:
<input name="realname" type="text" class="text" id="realname" value="<?php echo((isset($_POST["realname"]))?$_POST["realname"]:"") ?>" size="30" />
Works fine until I add the form validation for a couple fields and a captcha. The show if works fine but the problem is the the posted data doesn't show up in the fields after a submission with a validation problem (missing data or captcha failure).
Any idea what the problem is? Is it a bug or something I'm doing wrong? I've made sure the WA Server Validations Failed redirect is set to the same page. I've even tried leaving this blank and doesn't seem to make any difference.