photo / openphoto-wordpress

A WordPress plugin for OpenPhoto
http://theopenphotoproject.org
22 stars 8 forks source link

Lightbox effect? #9

Closed jemostrom closed 12 years ago

jemostrom commented 12 years ago

I like to have a lightbox effect on my photos, this works just fine with the current setup ... except that it links to the full-sized version. Would it be possible to add an option to use the 1024px version for the a-link?

randyhoyt commented 12 years ago

Our plugin works the same way the core WordPress media manager works, which is to link to the full-size version. That's the way we want the plugin work, at least by default. I'm open to adding a filter that would enable a theme or a plugin to change the default behavior. I'm curious how the lightbox plugin works with the images from the media manager:

Let me know the answers to this, and we can take a look at the best way to handle this request.

jemostrom commented 12 years ago

Yes, I agree that this should be the default behavior of the plugin but I love to see this as an option. This is why I usually scale my pictures to 1024 before uploading them to wordpress, but when stored on a photo site like OpenPhoto it makes sense to store the photos as large as possible which makes it cumbersome to use on a site.

I'm using various lightbox plugins, on this test site it seem to be the built-in functionality of a theme (the lightbox code seem to be named prettyPhoto) but I usually use 'lightbox plus'

It links to max size, in my case this usually means 3800+ x 2500+ ... which becomes a bit large for a lightbox effect :D

randyhoyt commented 12 years ago

I'll look into adding a filter. With that filter in place, a user could add some code to their theme that would cause those links to point to one of the scaled-down versions of the image that WordPress generated instead of to the full-size version.

jemostrom commented 12 years ago

OK

randyhoyt commented 12 years ago

I have added an option on the Settings > OpenPhoto page for the size to use of the link in File URL. It defaults to 'Original' but it can be changed to Thumbnail, Medium, or Large.

This is available in the development branch, commit f784505bda, and will be included in the next version.