This will work: http://www.php.net/array_merge
Call your checkboxes like so: a.php ========================================== <form action="b.php" method="post"> <input type="checkbox" name="a1" value="A"><br> <input type="checkbox" name="a2" value="B"><br> <input type="checkbox" name="a3" value="C"><br> <input type="checkbox" name="a4" value="D"><br> <input type="checkbox" name="a5" value="E"><br> <input type="checkbox" name="a6" value="F"><br> <input type="submit" name="submit" value="SUBMIT"> </form> ========================================== then post it to the desired page and do something like this: b.php ========================================== <?php $foo = array_merge($_POST['a1'],$_POST['a2'],$_POST['a3'],$_POST['a4'],$_POST['a5'] ,$_POST['a6']); echo $foo; // Returns an array echo "<pre>"; print_r($foo); // Look whats in the array echo "</pre>"; ?> ========================================== Best of luck, Craig "B.C. Lance" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > if you can't use [] for the checkbox, the only way out is to have unique > name for each checkbox. > > otherwise, php will always be returning the value of the last checked > checkbox if all checkboxes share the same name without the []. > > --lance > > Alex Shi wrote: > > How to ontain data from a group of checkbox using same name? > > For example, in a form there're 6 checkboxes and all named as > > "Interesting_Area". I know if put a pairs of square brackets at the > > end of the name then in php all the values of them can be ontained. > > However, for some reason I cannot use square brackets. Please > > help me out if anyone know how to do the trick. THanks! > > > > Alex > > > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php