How to get lightgallery youtube thumbnails?

Viewed 2172

I'm trying to use this plugin: https://github.com/sachinchoolur/lightGallery

What i can't understand is - does it generate thumbnails for images/video?

And i can't get thumbnails from youtube using the docs...

CSS:

<link rel="stylesheet" href="/static/css/lightgallery.min.css">
<script type="text/javascript" src="/static/js/lg-fullscreen.min.js"></script>
<script type="text/javascript" src="/static/js/lightgallery.min.js"></script>
<script type="text/javascript" src="/static/js/lg-thumbnail.min.js"></script>
<script type="text/javascript" src="/static/js/lg-video.min.js"></script>

JS:

$('.light-gal-item').lightGallery({
    thumbnail: true,
    thumbWidth: 120,
    thumbContHeight: 90,
    loadYoutubeThumbnail: true,
    youtubeThumbSize: 'default'
});

HTML:

<div class="light-gal-item">
    <a href="http://www.youtube.com/watch?v=P5_GlAOCHyE" data-src="http://www.youtube.com/watch?v=P5_GlAOCHyE">
        <img src="http://www.youtube.com/watch?v=P5_GlAOCHyE"
             width="120" height="90" />
    </a>
</div>

It does images like that... but even so, i cant figure out if it does thumbnails, or if it needs them by different url...

And it doesn't make youtube thumbnails... HELP!

1 Answers
Related