PDA

View Full Version : want to multiple images to open in one lightbox.



nisha
01-13-2009, 10:40 AM
1) Script Title: Lightbox image viewer 2.03a

2) Script URL (on DD):

http://www.dynamicdrive.com/dynamicindex4/lightbox2/index.htm

3) Describe problem:

i have used Lightbox image viewer 2.03a many times in my projects and i find it great script, but this time i have a problem that i want to link a light box on one single image which onclicked will show multiple images on clicking next/previous.
insteaded of the usual differenct gallery images each linked to the lightbox with an unique group name.

So what have i to modify in the code to achieve the desired.

Help and suggestions by anybody will be appreciated.

jscheuer1
01-13-2009, 04:19 PM
If you just want one thumbnail or link, you still need the others in the group, but they require no text or image, so need not be seen. Many have done this, ex:


<a href="first_img.jpg" rel="lightbox[mygroup]">Trigger Text or Image Tag</a>
<a href="second_img.jpg" rel="lightbox[mygroup]"></a>
<a href="third_img.jpg" rel="lightbox[mygroup]"></a>
<a href="forth_img.jpg" rel="lightbox[mygroup]"></a>
<a href="fifth_img.jpg" rel="lightbox[mygroup]"></a>


If your styles create layout problems with the unseen links (they probably will not), just remove the display of those items:


<a href="first_img.jpg" rel="lightbox[mygroup]">Trigger Text or Image Tag</a>
<div style="display:none;">
<a href="second_img.jpg" rel="lightbox[mygroup]"></a>
<a href="third_img.jpg" rel="lightbox[mygroup]"></a>
<a href="forth_img.jpg" rel="lightbox[mygroup]"></a>
<a href="fifth_img.jpg" rel="lightbox[mygroup]"></a>
</div>

nisha
01-14-2009, 05:12 AM
hi John,

Thanks for the solution, i do appreciate your suggestions. I also tried and was sucessful in achieving what i required. Yes i did the same thing which you have suggested over here. Adding the images in the same group but keeping them in blank links.

so now it code is working. i am able to show more then 5 images on clicking just one thumbnail.

Thanks for helping.