Hi,
I'm using the NextGEN Gallery widget to display a gallery in my sidebar and I want to link these thumbnails directly to a url rather than the original sized picture.
I've created a custom field called 'link' using the NextGEN Custom Field plugin as instructed to do here.
Ive worked out the which line of .php needs editing and tried using the same code as the guide above but to no luck.
In nextgen-gallery/widgets/widgets.php
if (is_array($imageList)){
foreach($imageList as $image) {
// get the URL constructor
$image = new nggImage($image);
// get the effect code
$thumbcode = $image->get_thumbcode("sidebar_".$number);
// enable i18n support for alttext and description
$alttext = htmlspecialchars( stripslashes( nggGallery::i18n($image->alttext) ));
$description = htmlspecialchars( stripslashes( nggGallery::i18n($image->description) ));
//TODO:For mixed portrait/landscape it's better to use only the height setting, if widht is 0 or vice versa
<strong> $out = '<a href="' . $image->ngg_custom_fields["link"] . '" title="' . $description . '" ' . $thumbcode .'>'; </strong>
Using $image->ngg_custom_fields["link"] doesn't work as none of the defined links appear, all images link to http://unwantedsound.co.uk - my website.
Can anyone help?
Thanks in advance.
Aaron