Save image in blob

Asked

Viewed 657 times

0

How to write this image code to the blob?

data:image/jpeg;base64,/9j/4AAQSkZJRgABAgAAAQABAAD/2wBDAAgGBgcGBQgHBwcKCggLDSkODQwMDRsUFR...

I just took a piece of it 'cause it all wouldn’t fit in here.

just send the code to the blob field in the database? or need to do some preparation before?

  • Enter part of the Insert code or hairs say if it is mysqli, Pdo etc

  • Is it really necessary to save the image in the database? Wouldn’t it be better to save it in a physical folder and persist only the same address?

  • @rray yes is Mysql

1 answer

0


I managed to solve the problem, I just needed to give a mysql_real_escape_string in the image code and send directly to the mysql database in the blob field

Browser other questions tagged

You are not signed in. Login or sign up in order to post.