Deleting multiple names from the database at once

From: Date: Fri, 01 Sep 2000 17:01:56 +0000
Subject: Deleting multiple names from the database at once
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-14838@lists.php.net to get a copy of this message
Hi all Last email I received from some mailing-list, started "Hi, My name is John and I have a problem..". I thought I won`t start like this, but I still need some help. Anyway, I have a list of names, e.g ->John ->Mary ->Someone else I get these names from the database using while this, echo this method. e.g: $getinimesed = mysql_query("SELECT * FROM inimesed"); echo "<FORM METHOD=POST ACTION='adminpage.php3?adminame=$adminame&adminpass=$adminpass&id=id'>"; while ($see = mysql_fetch_array($getinimesed)){ $nimi = $see["name"]; $code = $see["isikukood"] echo "<INPUT TYPE='checkbox' name='$code'><a href='javascript:openit()'>$name</a><BR>"; } echo "<INPUT TYPE='Submit' VALUE='DELETE'> </FORM>"; Right now it puts the checkbox in front of all names and below is the sumbit button. How can I delete all the names, which are checked (checkboxes), from the database? Logically taken, it should be quite easy, but I thought about it and havent`t managed to solve this thing myself. So any help is appreciated. Thank you in advance, Siim Einfeldt

« previous php.general (#14838) next »