I am in the process of creating a PHP/MySQL forum-based website. This is my first time working with PHP and MySQL; I have a few questions.
I want users to be able to upload .pdf files along with their posts. How is this done? How does the system handle such uploads? Is there a maximum allowable size for an attached file to be posted?
Any advice would be very much appreciated.
uploading files into my forum-based website
1 reply to this topic
Posted 02 June 2006 - 03:01 PM
In principle, if it's your forum, there are no such limits; however, PHP usually has a maximum execution time for each script, which limits upload size from a practical sense. Also, MySQL has a maximum query size as well, meaning you can't upload a 10MB PDF file all at once. As far as the PHP side goes, you can change this maximum timeout; on the MySQL side, it's not so simple. IMHO, the best way to go is simply to store the file on the server OUTSIDE the DB, and simply have a DB table that stores the path, filename and filesize of each upload.
Seriously... if people don't start reading this before posting, I'm going to consider not answering at all.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users