Register and display image in database with PHP [duplicate]

1

Hello, I would like to know how I can register an image in the database and how do I display it there, I searched the internet and saw that the field in the database has to be as longblob or has a varchar poderser, as I watched in a tutorial in which the face puts varchar in the field in which it saves the image. Thanks!

    
asked by anonymous 03.09.2018 / 20:22

1 answer

0

Friend, possible is. There is a file type in MySQL named blob . I have tried to perform some tests to save an image inside MySQL, it never worked cool, the image is well distorted.

The ideal is to save the image url in the database and upload the file.

    
03.09.2018 / 20:46