[SOLVED] Gallery - using External Links on thumbnails?

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
beherenow_uk
Forum Members
Forum Members
Posts: 103
Joined: Fri Nov 28, 2008 11:26 am

[SOLVED] Gallery - using External Links on thumbnails?

Post by beherenow_uk »

Hi,

I have CMSMS 1.9.3, Gallery 1.4.4.

I have searched all over... Im trying to get the href of the thumbnails linking to an external link that I have entered into an additional field definition on each image instead of the thickbox or fancybox etc. I just can't get it to work...

In my Gallery template I have:

Code: Select all

{foreach from=$images item=image}
<div class="img">
<a href="{$fields.my_great_link.value}" title="{$image->titlename}"><img src="{$image->thumb|escape:'url'|replace:'%2F':'/'}" alt="{$image->titlename}" /></a>
</div>
{/foreach}
But i can't seem to be able to get the field definition (with alias 'my_great_link') to show the link that I entered into that field.

Please could someone help?

Thanks, Karl.
Last edited by beherenow_uk on Thu Feb 24, 2011 10:26 am, edited 1 time in total.
beherenow_uk
Forum Members
Forum Members
Posts: 103
Joined: Fri Nov 28, 2008 11:26 am

Re: Gallery - using External Links on thumbnails?

Post by beherenow_uk »

Ok I found it with a bit of trial and error.

Turns out I needed $image-> at the start of the tag. So my code for the template to call my specific custom field is:

Code: Select all

{$image->fields.my_great_link.value}
Hope this helps someone.
Jos
Support Guru
Support Guru
Posts: 4017
Joined: Wed Sep 05, 2007 8:03 pm
Location: The Netherlands

Re: [SOLVED] Gallery - using External Links on thumbnails?

Post by Jos »

If you have any idea how to describe this better in the module help, I'd be glad to hear ;)
http://wiki.cmsmadesimple.org/index.php ... tom_Fields
beherenow_uk
Forum Members
Forum Members
Posts: 103
Joined: Fri Nov 28, 2008 11:26 am

Re: [SOLVED] Gallery - using External Links on thumbnails?

Post by beherenow_uk »

Hi Jos,

I didn't know that was there. But you are correct, it explains it perfectly. Thanks. ;)
Post Reply

Return to “Modules/Add-Ons”