mysql_real_escape_string and addslashes are both used to escape data before the database query, so what\'s the difference? (This question is not ab
mysql_real_escape_string
addslashes
case 1:
$str = "input's data"; print mysql_real_escape_string($str); input\'s data print addslashes($str); input\'s data;
case 2:
$str = "input\'s data"; print mysql_real_escape_string($str); input\'s data print addslashes($str); input\\'s data;