Forum Moderators: coopster
I simply dont know how to go about getting this to happen, short of running a new query for each & every user, this seems kinda silly to me. Can you please point me in the right direction for this?
Many Thanks in Advnace
Netvyper
There was a recent thread on the subject. Check this out
[webmasterworld.com...]
This might be helpful too, but I think you're asking a more advanced question than the one in this post:
[webmasterworld.com...]
unsure how to define which row of data from the page relates to which row in the table though.
You need to get your primary key in there somehow. One way is to use it as the array index for your checkbox as in
<input type="checkbox" name="active[123]">
Then when you process the post data, you can do a foreach
foreach ($_POST['active'] as $key=>$val)
{
$query = UPDATE mytable SET active='1' WHERE user_id = '$key';
}
something like that