Automatically resizing original images?

Greetings.

I would like to know how can I tell ZenPhoto that it should resize all the images (we upload) to 1600 px (at image's longest dimension) and throw away the original photos. The thing is that original photos can be 5000 pixels long or wide (while still being under 2 Mb filesize limit), and we would like GD to take care of the resizing.

We want to achieve the following workflow:

1) people will upload the images of different sizes and dimensions as a ZIP file to an album
2) ZenPhoto controls the files, and if any of them is bigger than 1600 px on either dimension, it resizes the image at quality 65 %
3) all the images appear in the album folder, and as the result of the above manipulations, there are no images with dimensions bigger than 1600 px. They all are resized, and the huge originals are deleted.

I have been searching everywhere for the solution, and the only thing I came upon was this thread http://www.zenphoto.org/support/topic.php?id=1774#post-10243 But I am not sure whether it is what I am looking for.

Thank you in advance for your help.
admin of http://behindthephoto.org

p.s.: I know that Coppermine had this function, but I switched from it, because I liked the simplicity and look of ZenPhoto.

Comments

  • acrylian Administrator, Developer
    Sorry, Zenphoto does never touch the original images uploaded and there is no other workaround than resizing images before uploading. But Zenphoto uses these original images to generate resized versions to be displayed on the site as thumbnails and "sized images".
  • Oh, I see. Thank you for the quick reply. So it means I will have to tell everybody to downsize the pics on their computer in advance. Minor inconvenience, but I think it is still a wonderful program, and I will continue to use it in spite of this :)

    A quick question: is it planned in the future, to add this functionality?

    Thank you again for the fast feedback.

    p.s.: I have raised all this, because I wanted to find a way to automatically reduce the file size so that the server space is not depleted fast.
  • We will not ever resize the original image. It is only needed to resize original images if your server is either too slow or does not have enough memory for Zenphoto to process the image when it makes a cache copy in the sizes you need. In both these cases it would be pointless for zenphoto to resize the orignal since it is not able to resize in the first place.
  • My only concern was the space on the server. :) But thank you for the explanations, I appreciate that.
  • But what if it uses a javascript? Then the resizing would be happening on the computer and not on the server, right? I found this script (http://javascript.internet.com/miscellaneous/automatic-image-resizer.html), but I have no way of putting it to use. There are a lot of users though that would like a script which would resize the images before the upload on admin-upload.php.

    This would make it much easier for galleries with many users which maybe don't know how to resize with Photoshop, don't know the maximum memory available for php or don't know the admins preffered size for images.

    Edit: Or maybe using this script on the begining of the uplodify script? http://atomgiant.com/2006/05/30/resize-images-with-javascript/
  • acrylian Administrator, Developer
    This would make it much easier for galleries with many users which maybe don't know how to resize with Photoshop, don't know the maximum memory available for php or don't know the admins preffered size for images.
    I am not convinced. Who is working with Photos or other images should really have at least basic knowledge of image resizing (sorry, if you can effort Phootshop you should know how to resize images, right??). The maximum memory is stated on the zenphoto backend. To tell these things to a client is the task of a professional web designer. If you do it all yourself you should learn some things before doing it, as with all things.
  • I can understand both points of view here. It really depends on the gallery usage. As a gallery operator/photo enthusiast etc, you should of course be able to re-size and edit your images and the like. However, if you think on the other side of the coin, there are a lot of people who don't know how to do that, and if you as a gallery operator are offering fast, simple galleries that do most of the work for you, then you'd likely have more users.

    Two sides of the same coin really, however if you as a gallery maintainer/operator are gearing your gallery for simple end-user usage, you should be technically sound to make the changes needed as well.
  • acrylian Administrator, Developer
    Well, I do generally understand, but Zenphoto can't do everything. Espceially as most sites will be on shared hosting whose servers are not able to do the resizing of really big images anyway even if we had that feature!
    See http://www.zenphoto.org/2009/03/troubleshooting-zenphoto/#11.

    We generally listen to what our users say but we are also not a company, we are volunteers.

    If a user has not at least the basic knowledge of image resizing or willing to learn you can assume that this will most likely will be a user that will not be able to upload and install Zenphoto on a server himself, too. So that user will have some kind of help by someone and this someone — if doing his job correctly — should be able to "teach" some kind of usage basics. I think we really are not talking about advanced knowledge here.

    And I did setup ZP sites for users with are not really that computer savy, too. Anyway, we appreaciate discussions like this.

    Regarding the javascript above: That seems to resize the display of an image on the fly. This is not the same as actually processing the file itself and saving it. I am not sure if it is possible using JS only. Our admin image crop tool uses J/jQuery but also needs PHP (the server) again for the actually processing of the image and then we have the above mentioned limitation again. (Proof me wrong though).
Sign In or Register to comment.