Michael Mason wrote:

I'm new to MySQL and already very impressed with it's flexibility, speed and functionality. This in mind, I am looking for a way to allow users to upload documents to the server for later retrieval by an administrator.



Can this be done or will I have to find a nasty third party tool...?

You should be able to do this, but be aware that storing arbitrary binary data might have security implications. Basically, what you end up doing is having a table something like this:

create table user_files(user_name varchar(255) not null, user_file blob);

Then you use your html code on a web page to let users upload a file. You take that file and insert it into the database. I've done it before and it works ok. Just make sure to check that if someone uploads an executable file you don't accidentally execute at some point.

I don't have code handy to share, but if you need some I could probably knock something out quickly.

bob

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to