On 04 November 2003 20:43, Pablo Gosse contributed these pearls of wisdom:
> On Tuesday, November 04, 2003 12:45 PM Kevin wrote:
>
> [snipped]
>> How can I test for it without getting an error if it is not
> checked??
> [/snipped]
>
> Hey Kevin. Use isset($var) to test if a var has been set.
>
#x27;checkboxname'] == 'on')
{
echo 'Selected';
}
else
{
echo 'Not selected';
}
Cheers,
Pablo
-Original Message-
From: KB [mailto:[EMAIL PROTECTED]
Sent: Tuesday, November 04, 2003 12:45 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Handling chec
Hi,
I have a page with a Form and a Checkbox.
I have a second page which wants to do something depending on if the
checkbox is selected or not.
If its selected there is no problem. But if I tryand do anything if it
isn't selected then it says the variable is 'undefined'. How can I test for
it w
3 matches
Mail list logo