Jump to content
Latest News: (loading..)
leatherdealer

Automatically resize Images once uploaded

Recommended Posts

Hey guys and girls,

I hope you're doing well.

I'd like to know where in osc 2.3.3 handles the image uploads from the categories.php

I've found a nice github repo for image resizing. I'm neither a newbie nor a  noob at PHP, but I need to know where the image upload is being handled to be able to properly add the functions for image resizing. 

https://github.com/Nimrod007/PHP_image_resize That's the repo

Any help is greatly appreciated

Share this post


Link to post
Share on other sites
14 hours ago, clustersolutions said:

admin/categories.php

you can also use convert if your host has it installed. it's easy peazy.

Hi, I'm my own host. I have multiple dedis. What's the correct name of the "covert" thing ? 

Share this post


Link to post
Share on other sites

If this is a one-time effort for a photo, why not just use free image processing software such as GIMP? It's probably best to crop and resize on your PC (before uploading), where you have immediate feedback, rather than hoping that any server-side resizer did the desired thing. You certainly don't want your server to be constantly resizing images as it feeds them out, nor feeding huge image files to the browser to be scaled down there. You may want to have several sizes on hand, such as a full size display, a thumbnail, and possibly something in-between. Use a "crop" function in the image processor to trim the photo to the desired aspect ratio, rather than simply stretching or squeezing in one dimension to get the desired shape.

Edited by MrPhil
add comment on sending large image files

If you are running the "official" osC 2.3.4 or 2.3.4.1 download, your installation is obsolete! Get the latest community-supported responsive "Edge" release

Share this post


Link to post
Share on other sites

You might also want to have a look at the Kiss Image Thumbnailer add on.   Perhaps it'll do what you want.

Dan

Share this post


Link to post
Share on other sites
5 hours ago, leatherdealer said:

Hi, I'm my own host. I have multiple dedis. What's the correct name of the "covert" thing ? 

@leatherdealer, "convert" is the program and it is part of ImageMagick.

https://www.imagemagick.org/script/install-source.php

I probably wouldn't install from source, unless you really want to have the C and etc compiler installed. You should be able to find the binary for your distro. For Centos, I think it is, yum install ImagicMagick, or you can just do a yum search.

There could be modules that you can just use to get what you need, but as far as cropping is concerned, you probably have to do it manually as I have done countless number of photos after a fashion photo shoot...yep, do it manually.

I use convert basically to scale the pixel size down, and as well as preprocessing and creating the different image sizes that I need. Also, during the processing, I also rename the output image file based on the product description, it did help with image SEO...

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×