Jump to content

Beating the PHP upload limits


Recommended Posts

I tried to search this but couldn't find any answers to the problem, but I know others have the same issue, so here it goes;

Since I have my website on a shared hosting (webfarm), the provider put up limits for the web-upload (12Mb) which is not much when selling digital products.

I can upload much more using FTP but, like others have tried, it didn't help me much to just rename the file afterwards.

Is there a way to work around this, or some one who might have a 'hack' or implemented some code to make this work??

Link to comment
Share on other sites

I tried the walk-through as descibed in post Upload Digital Products Via FTP but it didn't work.

The error message I got was this:


Fatal error:  Allowed memory size of 25165824 bytes exhausted (tried to allocate 30187521 bytes) in /customers/incomm.dk/incomm.dk/httpd.www/webshop/get-file.php on line 104



Any suggestions on how to beat it? Because I know I can upload very big files and download them, but somehow the download procedure in PrestaShop goes through some kind of database/PHP memory restrictions.

Link to comment
Share on other sites

thanks m8, unfortunally it didn't work - I'm parked at one.com and just got off with one of their online supporters who said, that this limit cannot be changed at all, so I'm back to square one.

The only way is to FTP the file and somehow 'trick' it into the PS database - or rewrite some of the code, but I'm no PHP wizard (far from it).

Link to comment
Share on other sites

that was also my first attempts (as I wrote in post #2), but when people then bought and downloaded the file, all they got was a file at 288 bytes with the coding I show in post #2 .... :(

It looks like not only the upload goes through the limits of PHP but also when people press the link, it somehow goes through a download limit. Though I don't know how they've programmed the redirecting stuff, but I suspect the 'feature' is in there somewhere.

Using FTP I can easily upload and download 500+ MB - and using direct web linking I can download as big files as I want.

Link to comment
Share on other sites

I'm a customer at one.com too. I tried overwriting the file via FTP as suggested. I could download appr. 24 MB of a 64 MB file.

Perhaps you should consider another hosting. The upload limit for domaindirect.dk is 48 MB (they will host your domain for free!). At unoeuro.com the limit is 80 MB (EUR 1,15/month). At Gigahost.dk you can tune the limit to 128 MB (DKK 20/month) (not the best choice in my opinion when considering stability and speed).

/Kjeld

Link to comment
Share on other sites

  • 2 weeks later...
I'm a customer at one.com too. I tried overwriting the file via FTP as suggested. I could download appr. 24 MB of a 64 MB file.

Perhaps you should consider another hosting. The upload limit for domaindirect.dk is 48 MB (they will host your domain for free!). At unoeuro.com the limit is 80 MB (EUR 1,15/month). At Gigahost.dk you can tune the limit to 128 MB (DKK 20/month) (not the best choice in my opinion when considering stability and speed).

/Kjeld


Check out http://www.hitchhosting.com, they have unlimited uploads.
Link to comment
Share on other sites

×
×
  • Create New...