Then I would do what John Holmes suggested.

---John Holmes...

Or name them as an array, "user[]" so that you have a $_REQUEST['user']
array. Checkboxes are a little pecular in how they come across into PHP. If
you search the archives you'll get some good examples.

---John Holmes...






From: "Greg" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Re: [PHP] checkboxes & php
Date: Fri, 24 Jan 2003 15:37:06 -0500

I want to be able to let people check multiple values. I want them to be
given a list of usernames and check the ones they want deleted, so a radio
button won't work. If you go to Yahoo mail and select more than one
checkbox, you can delete more than one item. I looked at the source and all
the checkboxes are called "Mid". Any ideas?
/Greg


"Edward Peloke" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> why would you give them all the same name? I can see this for radio
buttons
> but not checkboxes.
>
> -----Original Message-----
> From: Greg [mailto:[EMAIL PROTECTED]]
> Sent: Friday, January 24, 2003 3:27 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] checkboxes & php
>
>
> If I have 3 checkboxes labeled "user", but each one has a seperate value,
> how do I get the values of each checkbox? For example, how would I tell
if
> the following checkboxes are checked?
>
> <input type="checkbox" name="user" value="1">
> <input type="checkbox" name="user" value="2">
> <input type="checkbox" name="user" value="3">
> <input type="submit" name="Submit" value="Submit">
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE* http://join.msn.com/?page=features/junkmail


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to