I've been wrestling with the same issue. I had some code loop through and
create an arbitrary number of checkbox inputs with the name 'foo[]'
I then attempted to access the array using:
foreach ($foo as $bar)
{
echo $bar;
}
but I got error messages telling me that $foo is not an array :-(
I'm using Netscape 4.7 something on Red Hat 6.2 ... could this be an
issue? I know Netscape can be pretty buggy and fussy at the best of times.
Michael
On Wed, 29 May 2002, 1LT John W. Holmes wrote:
> If you name the form elements as arrays, then yeah, they are pretty much the
> same.
>
> <input type=checkbox name=foo[] value=one>One
> <input type=checkbox name=foo[] value=two>Two
> <input type=checkbox name=foo[] value=three>Three
>
> When submitted, $foo will be an array containing the values that were
> checked. If a box was not checked, it won't have any value in the array.
>
> i.e. If you check One and Three, then you'll have a $foo array like this:
>
> $foo[0]='one';
> $foo[1]='three';
>
> ---John Holmes...
>
> ----- Original Message -----
> From: "Brad Harriger" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, May 29, 2002 8:56 AM
> Subject: [PHP] HTML Checkboxes and PHP variables
>
>
> > Are HTML Checkbox values handled the same way as Select Multiple tags?
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
>
>
--
--------------------------------
n i n t i . c o m
php-python-perl-mysql-postgresql
--------------------------------
Michael Hall [EMAIL PROTECTED]
--------------------------------
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php