[英]Error in MySQL/PHP real_escape_string UPDATE function
$query = sprintf("UPDATE populationgender SET male='%s', female = '%s' WHERE popgenderid='4'",
mysql_real_escape_string($male),
mysql_real_escape_string($female));
Is this a valid sprintf code? 这是有效的sprintf代码吗? because when i use this it does nothing hehe it is connected via googlemaps btw :) pls help thanks :)
因为当我使用它时,它什么都不做,而是通过googlemaps btw连接的:)请帮助谢谢:)
You have used escape in javascript as well as php. 您在javascript和php中都使用过转义。 Try using escape in javascript and unescape in php.
尝试在javascript中使用转义,在php中使用unescape。
$myvar = urldecode($_GET["male"]);
this will work 这会工作
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.