views:

164

answers:

2

I have a list of checkboxes like you would see in most email clients (You tick a box press delete then it deletes an email).

<input type="checkbox" value="yes" name="box[]" />

The problem stands here ...

print_r($_POST['box']);//Returns nothing at all ...

var_dump($_POST['box']);// returns null...

I was reading something about register globals that php5 has turned it off for security reason.

Does anyone know what my options are ?

A: 

$_POST['box'] being empty doesn't look to good.

Have you checked that you are wrapping form tags around the inputs and making sure everything looks normal? Are any other inputs getting thru?

zaf
This is a comment, not an answer...
Felix Kling
Thnx the problem apperntly stands at enctype on the form ... should be a multipart instead of text/plain ..
Val
+2  A: 

Just found out by playing about with values.

Make sure you check for the enctype attribute on the tag

should be <form method="post" enctype="multipart/form-data">

Hope someone else could find this helpful .

Val