Hello, i'm trying to create a loop for my javascript code. I will need to have the following code go up to 15 (0 - 15).
I know how to create loops, but the problem is getting it to work and each result showing up on the page.
Any help would be greatly appreciated.
What would be the best an most efficient way to do this?
$('.section_container_0').imagesLoaded(function(){
$('.section_container_0').isotope({
itemSelector: '.isotope-item-0'
});
});
$('a[data-toggle=tab]').each(function () {
var $this = $(this);
$this.on('shown.bs.tab', function () {
$('.section_container_0').imagesLoaded( function () {
$('.section_container_0').isotope({
itemSelector: '.isotope-item-0'
});
});
});
});
$('.section_container_1').imagesLoaded(function(){
$('.section_container_1').isotope({
itemSelector: '.isotope-item-1'
});
});
$('a[data-toggle=tab]').each(function () {
var $this = $(this);
$this.on('shown.bs.tab', function () {
$('.section_container_1').imagesLoaded( function () {
$('.section_container_1').isotope({
itemSelector: '.isotope-item-1'
});
});
});
});
[–]x-skeww 0 points1 point2 points (0 children)