risolto:
grazie mille.Codice PHP:
public function updateProperty($data,$table,$r,$p)
{
if(is_array($data))
{
$i=1;
$query = "UPDATE `".$table."` SET ";
foreach($data AS $k => $v)
{
$query .= "`".$this->escape($k)."` = '".$this->escape($v)."'".(($i++ < count($data)) ? ', ' : ' ');
}
$query .= "WHERE `".$r."` = '".$p."'";
echo $query;
return mysql_query($query, $this->dbConn);
}
else
return false;
}