Large File Upload

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
face2six
Forum Newbie
Posts: 2
Joined: Tue Jul 25, 2006 7:31 pm

Large File Upload

Post by face2six »

Anyone care to take a stab at this.....

I have a client that uses a back-end that uploads files to thier site. In a previous incarnation(previous host,no safe mode) the client swears the site was able to upload files of 1.5mb in size. I can believe that because set_time_limit() function was used in the upload script which worked fine because safemode was off

Client switched hosting (new host , safe mode ON) and then site got droppend into my lap :roll:

So now client tries to upload files of 1.5 mb it times out (actually anything over 700k times out
)

New Host Admin will/can not change the default max_execution_time from the default of 30 secs.

So my question is this.

Based on the assumption that there has to be some site out there written in php that is capable of uploading 1.5 mb files to the server, with safemode on ( default) and max_execution_time 30 ( also default), and because you cant overide timeout with set_time_limit()

How can it be done?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

you can use .htaccess files to change the max_execution_time setting.
face2six
Forum Newbie
Posts: 2
Joined: Tue Jul 25, 2006 7:31 pm

Post by face2six »

I have tried this in an .htaccess

<IfModule mod_php4.c>
php_value max_execution_time 800
</IfModule>

but doesnt seem to have affected anything.
but im no htaccess file guru, so I maybe hosed it

not getting any server errors tho
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

check the setting in phpinfo().
Post Reply