Member
Member
teedog   2007-11-18, 04:58
#1

This is my first day digging around zenphoto, so pardon me if I ask something silly.

It appears that zenphoto creates 2 cached copies of each original image in my alburm: 1 thumbnail-sized copy and 1 copy sized according to the "image size" setting in admin options. Is it possible to have zenphoto not create the larger of the two cached copies? I like the thumbnail, but when I click on the thumbnail, I want to see the original image, not an intermediate resized version of the original.

Thanks in advance.

Member
Member
aitf311   2007-11-18, 05:57
#2

Pretty easy actually but you're killing the cool part of ZP!

open up your album.php theme file, look for where your images are printing, if its the default theme then its line 48, replace with and you're done.

Member
Member
teedog   2007-11-18, 06:09
#3

Thanks for the quick response.

Ah getFullImageURL() sounds promising. I was hoping there was a built-in option I overlooked so I wouldn't have to go code hacking.

I think I want to make the modification in image.php and not album.php though. I don't want to break out of zenphoto and view an image directly; I want zenphoto to display the fullsize image instead of the larger-than-thumbnail but still resized image. Does that make sense? I don't think I'm killing any cool part of ZP.

I plan to upload images that are already the correct size for fullscreen viewing, so having zenphoto resize each image unnecessarily seems a waste of system resources and disk space in my case.

Administrator
Administrator
acrylian   2007-11-18, 11:03
#4

Of course you have to edit image.php.

If you don't want to "hack" anything, you can set a bigger image size in the admin than all your original images have and then disable "allow upscale" in the admin (already default) and zp will show your images as uploaded.

But keep in mind that you compress your uploaded images the right way before, otherwise visitors with slower connections will have no fun.

Member
Member
teedog   2007-11-18, 18:25
#5

"you can set a bigger image size in the admin than all your original images have and then disable "allow upscale" in the admin (already default) and zp will show your images as uploaded."

Thanks, I thought about doing that too. However, images will still be recompressed and saved in the cache directory even if the image size is larger than the original and upscale is off, correct?

I had another thought, maybe a more elegant hack. Instead of changing the link in image.php of a theme, add an option in the admin interface, like "show original images" or "disable image resizing (except thumbnails)". If this option is enabled, the function that normally returns the URL of the resize/cached image returns the URL for the original image.

Member
Member
aitf311   2007-11-18, 19:17
#6

Let me try to get you straight....

You are wanting the gallery to function just as it does but instead of creating a resized image on image.php you want it to load the full image?

If that is what you want to do then change

`

Member
Member
teedog   2007-11-18, 19:38
#7

aitf311: Yep, that's exactly it. Thanks. ^_^

Wow, another point for zenphoto. You devs are so helpful and responsive. Cheers!

Administrator
Administrator
acrylian   2007-11-18, 19:38
#8

Yep, aitf311 is right. But better don't use the php short tag, instead write in full:
[img][/img]

Member
Member
jley   2013-03-17, 07:02
#9

Hello... This is a pretty old thread, but I have this same question, and it seems the code in image.php has changed.

I looked for some kind of option in the admin screens, but could not find it.

Anyway, I re-size my images before uploading them, so I don't want zenphoto to re-compress them, as it makes the images displayed in the gallery a bit fuzzy.

any advice? Thanks!

Member
Member
jley   2013-03-17, 07:11
#10

Ah... after a bit more digging, I see this was addressed in another thread at:
http://www.zenphoto.org/support/topic.php?id=10548

In particular, the last 2 posts there. And, it works...

Thanks!

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.