Is it possible to upload binary files to a mysql database?
I can't figure it out. This is what I did:
I made a form like this:
<FORM ENCTYPE="multipart/form-data" ACTION="upload.php" METHOD=POST>
<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="200000">
Send this file: <INPUT NAME="attachment" TYPE="file">
<INPUT TYPE="submit" VALUE="Send File">
My SQL Query is like this:
INSERT INTO ALBUMS ('file') VALUES '$attachment'
The field FILE is a type BLOB field.
The first result I got in the database whas the tempdir+tempfile.
After that I choosed to ad $attachment_name into the database.
But only the filename is stored in the database. Is it not possible to store
files into the database?
What I did now in the script is copying the file $attachment_name to a
share on the local network so that everyone can access files uploaded by
This is not the meaning of it all, it should be stored in the database.
Can somebody help me with this?
Please reply me at: mailto:[EMAIL PROTECTED] (my e-mail at work)
Thanks in advance.
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php