Download
User Rating: 0/5 ( 0 votes)
jQuery Museum is a zero-clutter jQuery image gallery.
-
Single file.
-
Works well on desktop & mobile.
-
Clicking the image (or hitting arrow keys) goes to the next one.
-
Clicking outside the image (or hitting escape) closes the overlay.
-
Images can be deep-linked (uses URL hash).
-
The browser back button is respected.
Source: muratayfer.com
1. INCLUDE JS FILES
<script src='http://code.jquery.com/jquery-1.10.2.min.js'></script>
<script src='jquery.museum.js'></script>
2. HTML
<div id='content'>
<img src='http://muratayfer.com/static/images/paintings/cat.jpg' />
<img src='http://muratayfer.com/static/images/paintings/bird.jpg' />
<img src='http://muratayfer.com/static/images/paintings/horse.jpg' />
<img src='http://muratayfer.com/static/images/paintings/snail.jpg' />
<img src='http://muratayfer.com/static/images/paintings/tiger.jpg' />
<img src='http://muratayfer.com/static/images/paintings/motosiklet.jpg' />
<img src='http://muratayfer.com/static/images/paintings/cyglobe.jpg' />
<img src='http://muratayfer.com/static/images/paintings/bubbles.jpg' />
<img src='http://muratayfer.com/static/images/paintings/evolution.jpg' />
</div>
3. JAVASCRIPT
$(document).ready(function() {
$.museum($('#content img'));
});
4. OPTIONS
var options = {
namespace: "msm", // for custom CSS class namespacing
padding: 25, // in case you would like a specific amount of padding on the lightbox
disable_url_hash: true, // disable using hashes in case your website already uses URL hashes for states
};
$.museum($('#content img'), options);