sachinchoolur / lightgallery.js

Full featured JavaScript image & video gallery. No dependencies
https://sachinchoolur.github.io/lightgallery.js/
Other
5.3k stars 596 forks source link

Launch Gallery from Button(link) #47

Closed rovo79 closed 8 years ago

rovo79 commented 8 years ago

Hello, Is it possible to launch a gallery by clicking on a button(link), instead of clicking a thumbnail?

I'm trying to do this with the list of images already on the page in HTML.

Thank you

rovo79 commented 8 years ago

I see now I was overcomplicating this. All that's needed is to list only first thumbnail and leave the others out. Hope this helps someone else.

Ex. HTML Structure

<div id="anchor-tag">
  <a href="img/img1.jpg">
      <img src="img/thumb1.jpg" />
  </a>
  <a href="img/img2.jpg">
LEAVE THIS THUMBNAIL OUT
  </a>
  ...
</div>