Difference between revisions of "Plugins"
Jump to navigation
Jump to search
| Line 1: | Line 1: | ||
==Color Box, Used to | ==Color Box, Used to pop up images, HTML, Youtube Videos== | ||
[http://www.jacklmoore.com/colorbox/ ColorBox used for pop up images] | [http://www.jacklmoore.com/colorbox/ ColorBox used for pop up images] | ||
<pre> | <pre> | ||
| Line 6: | Line 6: | ||
$('#flower-items').find('a').colorbox({ rel: 'gallery' }); | $('#flower-items').find('a').colorbox({ rel: 'gallery' }); | ||
}); | }); | ||
</pre> | |||
'''HTML''' | |||
<pre> | |||
$('#flower-items') | |||
.find('li:nth-child(2)') | |||
.colorbox({ | |||
'html': '<h1>Colorbox</h1><p>opn the color box</p>' | |||
}); | |||
</pre> | |||
'''Youtube''' | |||
<pre> | |||
$('#flower-items') | |||
.find('li:nth-child(2)') | |||
.colorbox({ | |||
'href': 'https://www.youtube.com/embed?v=Vn7vZJ0AIbE', | |||
'iframe': true, | |||
'width': 640, | |||
'height': 480 | |||
}); | |||
</pre> | </pre> | ||
---- | ---- | ||
[[#top|Back To Top]]< — >[[JQuery|Category]]< — >[[Main_Page| Home]] | [[#top|Back To Top]]< — >[[JQuery|Category]]< — >[[Main_Page| Home]] | ||
Revision as of 21:46, 26 December 2016
Color Box, Used to pop up images, HTML, Youtube Videos
ColorBox used for pop up images
$(function() {
"use strict";
$('#flower-items').find('a').colorbox({ rel: 'gallery' });
});
HTML
$('#flower-items')
.find('li:nth-child(2)')
.colorbox({
'html': '<h1>Colorbox</h1><p>opn the color box</p>'
});
Youtube
$('#flower-items')
.find('li:nth-child(2)')
.colorbox({
'href': 'https://www.youtube.com/embed?v=Vn7vZJ0AIbE',
'iframe': true,
'width': 640,
'height': 480
});
Back To Top< — >Category< — > Home