简体   繁体   中英

Inserting raw (binary?) image data into mysql? (PHP)

I've got a raw/(binary?) image like this:

ÿØÿà�JFIF��–�–�*!!!$'$ &(goes on forever);

when i try to insert this into mysql it doesn't work, the column type is set to longblob, any ideas?

我认为您需要在插入数据库之前使用mysql_real_escape_string对此进行转义。

mysql_real_escape_string for php_mysql
mysqli_real_escape_string or prepare statement for php_mysqli

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM