Give the checkbox value the id of the record to be deleted...if its checked,
then you can simply do an in string check in the sql
<input type='checkbox' name='user_loeschen value='".[User-ID]."'>
$sql = "delete from table where id in ("{$_POST['user_loeschen']}";
bastien
From: Ruprecht Helms <rhelms@xxxxxxxxxx>
Reply-To: rhelms@xxxxxxxxxx
To: php-db@xxxxxxxxxxxxx
Subject: handling of checkboxvalues
Date: Sat, 11 Feb 2006 17:48:48 +0100
Hi,
I want to have a function that delete some customers. The customers will be
selected by cklicking on in checkboxes. This is the line I codes the
checkboxes:
<input type='checkbox' name='user_loeschen[] value="id" id=".[User-ID].">
How can I use the checkboxvariable within another script and handle the
id-value? I little codescripplet will help me.
Regards,
Ruprecht
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php