Jump to content

Recommended Posts

there are indeed downfalls... what if the original is not a square image?

you will need to look at the image_create_from_gif/jpeg etc etc functions.

pretty straight forward.

I have an upload class that can handle such resizing of images etc. with the bility to take non- square images for re-sizing too (this could be adapted if you were of the inclination!)

my email is available on the left there (mainly use my hotmail acc.)
Link to comment
https://forums.phpfreaks.com/topic/27970-image-upload/#findComment-127944
Share on other sites

Yes there is.  Unfortunately I am at work at the moment and cannot quote from memory.

Look at the php reference document and read up on the image processing functions.  You will find what you are looking for.

It can be confusing and if you want some examples I have a number of working scripts that I would be happy to share.  One I have takes an uploaded image and automatically creates a thumbnail size version which more or less sounds what you are looking for.

Get back to me if you would like to see the script.

Michael
Link to comment
https://forums.phpfreaks.com/topic/27970-image-upload/#findComment-127948
Share on other sites

But that can make the image pixelate or distort - which is awful. Setting the attributes has always been a way to control the size of the image but if you want quality with it then you shoudl adopt a more robust strategy - like properly re-creating the images.
Link to comment
https://forums.phpfreaks.com/topic/27970-image-upload/#findComment-127978
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.