prova.Codice PHP:
function delete($idx = array())
{
$x = 0;
$where = '';
foreach( $idx as $campo => $valore )
{
$where .= $campo ' = \'' . $valore . '\'';
if( ++$x != count($idx) )
{
$where .= ' OR ';
}
}
return $where;
}
$query = mysql_query("DELETE FROM tabella WHERE " . delete($_POST['cancella']) . "");