Jump to content

Archived

This topic is now archived and is closed to further replies.

phpvolution

Cropping images

Recommended Posts

I just lately got back into PHP and am extremely rusty, so bare with me. I need to create a script that will go through a folder of images and crop each one to a certain dimension.

More specifically, these are all scanned images that are all the same dimensions and need to all be cropped the same size. So instead of going through hundreds or thousands of images manually I thought this would save me a bunch of time if I automated it. [img src=\"style_emoticons/[#EMO_DIR#]/wink.gif\" style=\"vertical-align:middle\" emoid=\":wink:\" border=\"0\" alt=\"wink.gif\" /]

I'm not sure where to start as I haven't dealt with cropping yet, and I'm not sure how I can cycle through all the images in a folder. If anyone could provide some direction on how to do this, it would be greatly helpful!

And for the record the image dimensions are:
1276 x 1754 pixels
and need to be cropped to:
915 x 1560 pixels

I'd also like to resize them after cropping but I figure that'd be asking a little much, are there any great tutorials out there on this?

Share this post


Link to post
Share on other sites
see
[a href=\"http://www.phpfreaks.com/forums/index.php?showtopic=95778\" target=\"_blank\"]http://www.phpfreaks.com/forums/index.php?showtopic=95778[/a]

Share this post


Link to post
Share on other sites

×

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.