J
(@jeroen1973)
hello,
The easiest way or the fastest, at least I guess is to edit shutter effect. In shutter-reloaded.js file you have these
if ( ! (S = t.I('shShutter')) ) {
S = document.createElement('div');
S.setAttribute('id','shShutter');
document.getElementsByTagName('body')[0].appendChild(S)
t.hideTags();
}
if ( ! (D = t.I('shDisplay')) ) {
D = document.createElement('div');
D.setAttribute('id','shDisplay');
D.style.top = t.Top + 'px';
document.getElementsByTagName('body')[0].appendChild(D);
}
If you create a div in you template file, for example image_wrapper
you can easly edit this line document.getElementsByTagName('body')[0].appendChild(D);
with
document.getElementById('image_wrapper').appendChild(D);
and this document.getElementsByTagName('body')[0].appendChild(S);
with document.getElementById('image_wrapper').appendChild(s);
however now it will open the lightbox effect after you click on thumbnail. So we need to load first image as page is loaded. So the fastest way just add this od document ready `
$(‘#ngg-image-1 a’).trigger(‘click’);
`
@matys1001 – Thanks for this suggestion … but as this is referring to NextGEN Gallery at roughly the time the branch changed to 2.0.x are you seeing this working as expected with the current release (version 2.0.65)?
– Cais.
@photocarti – your welcome – you know I did it the same day I posted the answer 😉 So I guess it works, you also need to change css a bit to make it works.
PS. To make it more usefull you can change the last code $('#ngg-image-1 a').trigger('click');
for the first element, so u dont need to get the specific ID .
$('.ngg-gallery-thumbnail:first a').trigger('click');
– so its gonna be very first element each time 😉
@matys1001 – Thanks for the follow-up … and confirmation!
– Cais.