Developer Support »

Prepopulating a checkbox not named as an array  (See more user questions)

No trouble, G!

For future reference, this is how to prepopulate a checkbox named in the conventional way for naming form fields, i.e without the square brackets:

<input type="checkbox" name="fruit" value="apple" <?php if(isset($fruit) && $fruit == "apple"){print " checked=\"checked\"";} ?>>Apple

Best wishes.

Charles Sweeney
https://formtoemail.com
The world's easiest feedback script!

On 26/06/2011 22:24, wrote:
> Disregard. I am such a dumb-ass. I'll just remove the pre-pop code. Geeze,
> I got so focused on the error message, not knowing php.
>
> Sorry!