HTTP_POST_VARS & checkbox arrays

From: Date: Sat, 06 Oct 2001 05:05:34 +0000
Subject: HTTP_POST_VARS & checkbox arrays
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-70195@lists.php.net to get a copy of this message
Let's say I have: filename: my_form.php ... <form method=post action=my_form_submit.php> <input type=checkbox name=dept[] value=admin>Admin <input type=checkbox name=dept[] value=hr>HR <input type=checkbox name=dept[] value=it>IT .... Now in "my_form_submit.php" I only use $HTTP_POST_VARS- how would dept[] be represented? I tried $HTTP_POST_VARS['dept'] but no luck- tried foreach($HTTP_POST_VARS[dept]) -didn't work. All other variables came through fine via $HTTP_POST_VARS. Thanks in advance. David

« previous php.general (#70195) next »