Re: HTTP_POST_VARS and Arrays
| From: | Matt Allen | Date: | Tue, 04 Jul 2000 01:46:56 +0000 |
| Subject: | Re: HTTP_POST_VARS and Arrays | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-4638@lists.php.net to get a copy of this message | ||
Hi,
Thats cool in theory, but shouldnt this test pass:
if (is_array($HTTP_POST_VARS["field_name"])) {
echo "ok";
}
it doesnt. Its like Field_Name isnt even getting passed though, like an
unchecked checkbox !
Matta
scottrus@ipass.net wrote:
>
> I think you need to look for the data as
> $HTTP_POST_VARS["field_name"][$n] where $n is the
> nth element of the $field_name array.
>
> Not 100% sure about this. You might also try looking
> for the data as $HTTP_POST_VARS["field_name[$n]"]
> but I don't think this looks valid in php terms.
>
> -- Scott
>
> On Tue, Jul 04, 2000 at 11:16:48AM +1000, Matt Allen wrote:
> > Hi All,
> >
> > When im walking the HTTP_POST_VARS array im not getting any data from
> > the submitted form if the element in the form was an array.
> >
> > For instance, If it it a multiple select list and nothing is selected
> > then the form element doesnt even appear in the HTTP_POST_VARS array,
> > not even as a NULL.
> >
> > Any Ideas?
> >
> > Matta
> > --
> > Matt Allen Linux/PHP eCommerce
> > Solutions
> > Linux Worx Linux Networking
> > www.linuxworx.com.au Consulting
> > matt@linuxworx.com.au
> > 0413 777 771
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > For additional commands, e-mail: php-general-help@lists.php.net
> > To contact the list administrators, e-mail: php-list-admin@lists.php.net
>
> --
> Scott
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
--
Matt Allen Linux/PHP eCommerce
Solutions
Linux Worx Linux Networking
www.linuxworx.com.au Consulting
matt@linuxworx.com.au
0413 777 771