icon Get the most out of Surmunity, read our tips here! Need an interesting blog to read? You've got to read the Surpass Blog! | Welcome! Please register to access all of our features.

» Surpass Web Hosting Forums » Discussions » PHP, MySQL » Problem with upload script.

PHP, MySQL General PHP questions. Or go to our PHPsuexec Forum >>

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread
Old April 28th, 2007, 8:50 PM   #1 (permalink)
Registered User
Fresh Surpasser
 
Joined in Jul 2004
Lives in California, USA
Hosted on Sonet
14 posts
Gave thanks: 2
Thanked 0 times
Problem with upload script.

Okay, I have a script I use to manage a site. It creates the directories and uploads/deletes/moves the files. The problem I'm having is that it won't allow an upload over 3MB. Since files that large are rare, it should be trivial to upload the file manually. However, because the directories are created by the php script, I can't write to the them. cPanel's File Manager won't allow me to change the directory's permissions, either. I tried writing a script that moved the manually uploaded file, but the permissions on the file won't allow the script to move it. Changing permissions in File Manager didn't help.

So, to make this easier in the future, how do I fix it to allow larger uploads, preferably up to 15MB(that's the max the script will allow)? My server is Sonet, if that makes any difference.

Thanks in advance...
Andy Olivera is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old April 29th, 2007, 3:49 AM   #2 (permalink)
mgk
Registered User
Excelling Contributor
 
Joined in Mar 2007
Lives in Wales
Hosted on dime999
610 posts
Gave thanks: 47
Thanked 46 times
Have you checked the php.ini for the the limit there?
__________________
Markus
mgk is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
This user thanks mgk for this great post!
Andy Olivera (April 29th, 2007)
Old April 29th, 2007, 5:51 AM   #3 (permalink)
Registered User
Fresh Surpasser
 
Joined in Jul 2004
Lives in California, USA
Hosted on Sonet
14 posts
Gave thanks: 2
Thanked 0 times
Mgk, the php.ini didn't work(tried it in both the script directory and public_html). However, your suggestion turned me on to another thread that dealt with setting the values through .htaccess. I tried that and now everything works fine.

Thanks for the help!
Andy Olivera is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old May 8th, 2007, 12:50 AM   #4 (permalink)
I'm Dope as Crack
Resident.
 
David's Avatar
 
Joined in Mar 2004
Lives in Asheboro, NC
Hosted on Pass 7
13,036 posts
Gave thanks: 7
Thanked 29 times
Some servers may still be using htaccess rather than php.ini. Thanks for mentioning what worked and what didn't.
__________________
David is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old October 9th, 2007, 11:05 PM   #5 (permalink)
Registered User
Fresh Surpasser
 
Joined in Mar 2005
Hosted on Pass6
16 posts
Gave thanks: 0
Thanked 0 times
Can you elaborate what did you do in .htaccess to get the upload working?
Ekhwan is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old October 11th, 2007, 11:44 AM   #6 (permalink)
Senior Member
Super #1
 
FredFredrickson's Avatar
 
Joined in Nov 2003
Lives in New Hampshire
1,182 posts
Gave thanks: 3
Thanked 22 times
I'd assume changing the max_upload_size

Also- notice that your php is running as nobody(99) so this means you're not running phpsuexec either. I'd contact support- cause the files you're uploading are vulnerable to other scripts running a muck
__________________
The Coding Blog - Follow along as we discover and discuss everything it takes to code an entire website, start to finish! [Latest Entry: 4/4/08 - Starting a Website]
FredFredrickson is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On