Hi,
I'm working on a form with textboxes, radiobuttons, checkboxes and a textarea field.
After submitting the form, the form is being validated on input. If not correct and a textbox is filled, the textbox will be filled with the entered value.
This goes for the radiobuttons and checkboxes as well. If they are enabled and the user submits the form, and it can't be processed, the enabled radiobuttons or checkboxes will be shown.
The same thing I want to do for a textarea. If the user adds some comments in a textarea, submits the form, and there is an error in the form, I would like to show the entered value in the textarea.
All input fields are working fine, execpt the textarea field. After submitting the form and the validation of the form is not ok, representing the form again looses the value entered in the textarea.
This is what I am trying to do with the textarea, but obviously it's not working. How should I handle the textarea and it's values to display after submitting the form?
<textarea name="comment" rows="5" cols="58" wrap="soft" <?php echo $_POST['comment'];if($_POST['comment']!=""){echo $_POST['comment'];}?>></textarea>
Thanks,
Zackat