OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Max Upload Limit Work-Arounds

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

Max Upload Limit Work-Arounds

Postby soj » Tue Nov 28, 2006 11:30 am

I've got an pdf article of a size exceeding shared server php upload limits. At this point we cannot afford a dedicated server, so I'm looking for a work-around. I can of course FTP the file.

I'm thinking I could upload a smaller dummy file via the system and then replace the file via FTP in the FILES directory. More work, but would this work okay? It looks like I will need to temprorarily change the permissions for the FILES directory in config.php in order to apply this workaround.

Also, has anyone used PERL as a workaround? Please See:

http://www.raditha.com/megaupload/upload.php

soj
soj
 
Posts: 151
Joined: Fri Oct 28, 2005 1:53 pm
Location: Norman OK USA

Postby asmecher » Tue Nov 28, 2006 12:53 pm

Hi all,

There are several places to check if you're having problems uploading large files:
  • Web server configuration (i.e. Apache or IIS)
  • PHP configuration (php.ini)
  • Occasionally, another system like a firewall will step in and cause trouble.
Apache 2.x, for example, has a LimitRequestBody directive that will prevent large file uploads. Note that file uploads are encoded, and are only part of the request that the web server receives, so a LimitRequestBody of 8 megs won't necessarily allow a file upload of 8 megs. You may be able to override these settings on a shared environment with an appropriate .htaccess directive.

There are several file upload limits in your PHP configuration file, php.ini:
  • max_post_size: This is analagous to the LimitRequestBody directive described above, but checked in PHP rather than in the web server code.
  • file_uploads: This is where file uploads are enabled or disabled.
  • upload_max_filesize: This is where you can define the maximum upload file size.
Likewise, it may be possible to override these settings with a .htaccess file; for example:
Code: Select all
php_value upload_max_filesize 10M
This will depend on your web server's security settings for .htaccess files; you can verify whether or not these work by generating a phpinfo output.

Regards,
Alec Smecher
Open Journal Systems Team
asmecher
 
Posts: 7734
Joined: Wed Aug 10, 2005 12:56 pm


Return to OJS Technical Support

Who is online

Users browsing this forum: No registered users and 6 guests