Jump to content

[Resolved] Uploading files larger than 350kb


Chris_St

Recommended Posts

Hi,

 

 

I would like to be able to upload images to a max of 750kb. Searching the forums I found this in a previous post from B Smither:

 

 

           In the file /classes/filemanager.class.php, line 25, set the max file size you want

 

 

I changed it to 75000 but it just gets an x on the upload and still says its too big max size 350kb

 

   

I also tried this from another post;

 

 

private $_directories;

    private $_mode; 

 

 

    private $_manage_cache;

    private $_manage_dir;

    private $_manage_root;

    private $_recently_uploaded = array();

    private $_sub_dir;

    private $_sendfile = false;

    //private $_max_upload_image_size = 350000;

    private $_max_upload_image_size = 6291456; // 6MB 

 

 

    public $form_fields = false;

 

 

Still no good. Can anyone tell me please if there any other ways to get larger files into cube cart images section?

 

 

Regards,

 

 

Chris

Australian United Artists

Link to comment
Share on other sites

in the newer versions you also need to adjust the javascript within the admin skin as there is a limit defined there. Previously the limit was only server side, now it does client and server side checks.

clear your browser cache or hard refresh (CTRL F5) after making the change.

From memory, I think it's in dropzone.js

Link to comment
Share on other sites

Just now, Noodleman said:

Yup, after every update unless you create a custom admin skin. but that's not a great idea because you probably want the updates :)

Agreed. It's frustrating we have to impose this limit. I develop on a mac and PHP is configured to be able to ask for extra resources when needed. I can upload a 10Mb file and PHP will create thumbnails. Unfortunately most hosting companies don't allow temporary resource spikes and we are bound to the fixed PHP memory limit. In this case many images over 350Kb will crash the store. Memory errors in GD crashes are impossible to catch. 

Although this limit is annoying.. I don't think we have much choice. I'd rather impose it then have a new merchant upload 5Mb files direct from their SLR then think CubeCart is crap because the server crashes out. 

Link to comment
Share on other sites

Thanks Guys,

I understand.

I have increased it to 750kb. Most images are OK at the 350kb limit but sometimes the clarity seems compromised when I compress vendors images. I will be resizing images from vendors to between 350 and 500kb so that should be OK,

Thanks

Link to comment
Share on other sites

It would be nice to make this limit easier to change/configure. For customer who have a dedicated server, VPS or decent hosting package then a higher limit is normally not a problem. If this could be a configurable via the store settings it would remove the need for this change as part of an update for quite a lot of stores.

If it breaks for somebody, they can easily reduce the setting to something more applicable to their environment and it could default to the current 350Kb limit.

 

 

 

 

DOH, I forgot I already requested it :)

https://github.com/cubecart/v6/issues/712

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...