Hey guys, ill try to make this simple. I want to make a GUI for a client so that they can delete news entries that they have posted. I figure I can code a site that will query the table for the news and post the titles of all of the news entries, and put a check box next to each one. The name of the check box will be the id number of the row in the MySQL table where the news entry is located. So if they click a check box, when they hit submit, it will send a query that will delete a row where the id number equals the name of the check box.
So i just want to know what my php would look like to collect all the id's of the clicked (on) checkboxes and run those id's through the query. Ill can write it up in psuedocode...
-
if(isset($_GET('Submit'))
-
{
-
if(there were checkboxes clicked)
-
{
-
get ID's;
-
while(you have ID's)
-
{
-
mysql_query("DELETE FROM news WHERE id=checkBoxName");
-
};
-
}
-
}
-
I just need the blanks filled in, a little push in the right direction would be great. I know it's simple, just ignorant to the solution. thanks in advance.