Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-05-16 23:05:58

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

how do i get lightbox/slimbox to play with upm_image/other?

I’m possibly missing something very simple, but how do I get the following sort-of-thing to output with upm_image, upm_article_image or a list of image IDs in a custom field?
(This example code was expanded from the Lightbox how-to page)

<a href="image1.jpg" class="lightbox"><img src="thumb_image1.jpg" /></a>
<a href="image2.jpg" class="lightbox"><img src="thumb_image2.jpg" /></a>
<a href="image3.jpg" class="lightbox"><img src="thumb_image3.jpg" /></a>

It’s driving me nuts.

Thanks!

hicks.

Offline

#2 2011-05-17 00:23:00

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

Re: how do i get lightbox/slimbox to play with upm_image/other?

Sorry, sussed it…

<txp:upm_if_article_image_list>
<txp:upm_article_image>
	<a href="<txp:upm_img_full_url />" class="lightbox"/><img src="<txp:upm_img_full_url />" /></a>
</txp:upm_article_image>
</txp:upm_if_article_image_list>

Offline

#3 2011-05-17 02:00:42

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,477

Re: how do i get lightbox/slimbox to play with upm_image/other?

Better with thumbnail etc.:

<a href="<txp:upm_img_full_url />" class="lightbox"><img src="<txp:upm_img_thumb_url />" width="<txp:upm_img_thumb_width />" height="<txp:upm_img_thumb_height />" alt="<txp:upm_img_alt />" /></a>

Offline

#4 2011-05-17 16:39:53

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

Re: how do i get lightbox/slimbox to play with upm_image/other?

That’s the code to do it from thumbnails, but my lightroom images are popping up from 480px-wide images as it is—too big for thumbs—they’re made that size by the css for their in-article appearance.
Thanks though!
h.

Offline

Board footer

Powered by FluxBB