Ok so I got a form and usability is important to me. If the user completes the form and then hits submit but there are errors on the form I have set values to echo back
e.g.
<input class="input_phone" name="phone" type="text" value="<?php echo $_POST['phone']; ?>" maxlength="15" />
The value entered will be back in the form field so that the user doesn’t have to retype every field.
How do i achieve the same effect with radio buttons?
<input class="radio" name="q1" type="radio" value="YES">
If i set the value to $_POST['q1'] How do I set it to YES?
It is same with input text, just with attribute
checked.