NYCPHP Meetup

NYPHP.org

[nycphp-talk] file uploads

John Lacey jlacey at att.net
Mon Dec 15 00:32:23 EST 2003



John Lacey wrote:

> 
> 
> Nasir Zubair wrote:
> 
>> John,
>>
>> Would it be possible for you to send the files to me too. I am also
>> interested in finding out how to do it.
>>
>> - Nasir
>>
>>
> 
> here's a php file and an htm "save file screen" that shows the major parts
> 
> if you look in the add_question.php.htm file's source, you'll see some 
> code near the bottom with hidden fields like "MAX_FILE_SIZE" etc... 
> that's the browser picture
> 
> in the functions.inc.php file you'll see a little ways from the top a 
> "pt_check_image" function -- that's the server-side story...
> 
> John
> 


also, don't forget about the file uploads in php.ini file -- 
  here's a section from one of mine: (note the max file 
size, change it to whatever you need)

;;;;;;;;;;;;;;;;
; File Uploads ;
;;;;;;;;;;;;;;;;

; Whether to allow HTTP file uploads.
file_uploads = On

; Temporary directory for HTTP uploaded files (will use 
system default if not
; specified).
upload_tmp_dir = ".;C:\XAMPP\xampp\tmp"

; Maximum allowed size for uploaded files.
upload_max_filesize = 2M


also, I recall something about a problem with large file 
uploads and the script max_execution_time, but I believe 
that was fixed in a later version of php










More information about the talk mailing list