Post by younghistory » Sun Jan 29, 2012 10:23 pm

I need to get pictures of my stuff to my site. However opencart looks like it doesn't even recognize my files.

After extensive googling (and correct me if I am wrong) the max size seems to be around 300kb or .3mb

My files average 3mb.....

Can this be changed?

If not do you guys know of anyway to get around this? My friend took the pictures with his camera. Should he use a camera with worse resolution? Are there sites that can make a jpg file size smaller?

Thanks

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Sun Jan 29, 2012 11:38 pm

upload them to the folder image/data using a ftp program

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Mon Jan 30, 2012 12:08 am

@victorj I have tried that. When I try to browse for the files using the image wizard the files cant be seen

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Mon Jan 30, 2012 3:20 am

try uploading a couple of smaal jpg files and see if they are showing up.

make sure that the right permissions apply to de folowing folders

image/data
image/catch
both should be 777.

also check the owner of the files is it you or apache.

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Mon Jan 30, 2012 4:08 am

@victorj yes small files do work. The issue is the file size..I need to know if you can either change the maximum size of open cart or if anybody else has some work arounds for this issuse

I have tried changing the upload directory field in php.ini suggested here http://dotnetfish.blogspot.com/2011/11/ ... ncart.html but that did not work

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Mon Jan 30, 2012 4:46 am

ther seems to be a file size restriction

open admin\controller\common\filemanager.php

find:

if ($this->request->files['image']['size'] > 300000) {
$json['error'] = $this->language->get('error_file_size');

alter 30000 into whatever you want
perhaps it solves the upload restriction

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Mon Jan 30, 2012 6:43 am

@victorj altering that piece of code indeed works. When I upload a picture a pop up says the "file has been uploaded successfully"

However the picture cannot be seen by the wizard ??? ??? ??? ??? ??? ??? ???

Looking in the cPanel file Manager, the file was indeed uploaded but its type is "text/x-generic"

any thoughts?

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Mon Jan 30, 2012 5:52 pm

Not at this moment.
Can not replicate on my hosting server nor at localhost.

It needs a closer look to see whats the problem.

download the data folder using ftp.
put it in a archieve and upload to a accesible part of your site and pm me the download link.
will take alook here if it works here using your pictures

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Tue Jan 31, 2012 5:31 am

@victorj

hey I figured out the problem. My picture files had the extension .JPG which cant be read as an image by cpanel apparently. Changing the file extension to .jpg fixed it

If anyone else is reading this use this command in a bash shell to change your .JPG files to .jpg in your picture directory

for i in *.JPG; do mv $i ${i/JPG/jpg}; done;

SO i guess to wrap this whole file upload confusion (for anyone who ran into the issue)

OPENCART has a default file upload cap. A very tiny one. If you navigate here:
admin\controller\common\filemanager.php

in the cpanel file manager you can change:

if ($this->request->files['image']['size'] > 300000) {
$json['error'] = $this->language->get('error_file_size');

to a file size of your choice. Note that the number is in bytes

Thanks and props to @victorj

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Tue Jan 31, 2012 5:42 am

Now you mention it that also is a filemanager problem.
it has to do with the extensions it allows and .JPG is not one of them.
actualy quit easy to reprogram.
will give it a go and post to try

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by victorj » Tue Jan 31, 2012 5:48 am

Redone filemanager.php
it now should accept extensions with capitals like .JPG .GIF

upload to admin\controller\common\filemanager.php

only for 1.5.1.3

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Tue Jan 31, 2012 6:00 am

@victorj

I spoke too soon!

The wizard cant see my image files anymore!!

But I saw them in the wizard yesterday...at least when I tested it with one .jpg file that was 3MB and not 20 of them

Is there restriction to the number of files in the image directory???

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Tue Jan 31, 2012 6:04 am

no the only limit is your hosting space.

backup you original filemanager and replace with the one posted.
beware upload ristriction is not altered yet.

interested if this tiny mod solves the problem

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by younghistory » Tue Jan 31, 2012 6:08 am

yea...it looks like there is a restriction on how many files are in the directory

after testing when you place more than around 2MB in the directory everything becomes invisible in the wizard( but not cpanel)....is there a place in the code that controls this?

Newbie

Posts

Joined
Thu Jan 26, 2012 2:01 am

Post by victorj » Tue Jan 31, 2012 6:21 am

Can not find anything in the code.
on my site there are around 1gig of pictures it takes some time to load but they all show up.

Did you actualy change the file extensions or are they still in capitals ?

Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com


User avatar
Expert Member

Posts

Joined
Sat Jun 25, 2011 4:09 am
Location - Alkmaar Holland

Post by preloved » Thu Feb 02, 2012 5:23 pm

Hi, i have the same issue with the size of the images. i use adobe photoshop and within that there is an option to bulk resize - it's just a case of selecting the folder and resizing the pixels - my site has a restriction of 1000x1000 pixels. it takes less than a minute to run and then the images will upload. hope that helps.

Selling gently used & preloved baby items!
check out www.prelovedbabystuff.co.uk


Newbie

Posts

Joined
Mon Jan 30, 2012 5:26 pm

Post by milhauz » Thu Apr 26, 2012 6:51 pm

Hi,
the reason, why you don't see images with big size is because of memory limit. Filemanager tries to make preview image for your big image and fails (not enough memory). If you have posibility to change this limit, it will solve your problem.

Newbie

Posts

Joined
Thu Apr 26, 2012 6:38 pm
Who is online

Users browsing this forum: No registered users and 5 guests