Instagram Feeds - by yogesh
<section class="content-instagram-feed">
<div class="col-wrapper clearfix">
<div class="instafeed-items" data-token="7371049852.1677ed0.dba3180e29b848f1b665fbe1902c3a53"></div>
</div>
</section>
<script src="https://cdn2.hubspot.net/hubfs/5490511/Cyclerun_Fitness_April2019%20Theme/Javascript/instafeed.min.js"></script>
<script>
function getIntaFeedToken(elem, id, token) {
var feed = new Instafeed({
get: 'user',
target: elem.toString(),
userId: id.toString(),
accessToken: token.toString(),
resolution: 'low_resolution',
limit: 8
});
feed.run();
}
jQuery(document).ready(function($) {
$(".content-instagram-feed").each(function(){
var o = $(this);
if (o.hasClass("init")) {
return;
}
o.addClass("init");
var headerId = "id-" + Math.random().toString().slice(2);
o.find('.instafeed-items').attr("id", headerId);
var userToken = o.find('.instafeed-items').data("token");
var userId = userToken.substr(0, userToken.indexOf('.'));
getIntaFeedToken(headerId, userId, userToken);
});
});
</script>
<div class="col-wrapper clearfix">
<div class="instafeed-items" data-token="7371049852.1677ed0.dba3180e29b848f1b665fbe1902c3a53"></div>
</div>
</section>
<script src="https://cdn2.hubspot.net/hubfs/5490511/Cyclerun_Fitness_April2019%20Theme/Javascript/instafeed.min.js"></script>
<script>
function getIntaFeedToken(elem, id, token) {
var feed = new Instafeed({
get: 'user',
target: elem.toString(),
userId: id.toString(),
accessToken: token.toString(),
resolution: 'low_resolution',
limit: 8
});
feed.run();
}
jQuery(document).ready(function($) {
$(".content-instagram-feed").each(function(){
var o = $(this);
if (o.hasClass("init")) {
return;
}
o.addClass("init");
var headerId = "id-" + Math.random().toString().slice(2);
o.find('.instafeed-items').attr("id", headerId);
var userToken = o.find('.instafeed-items').data("token");
var userId = userToken.substr(0, userToken.indexOf('.'));
getIntaFeedToken(headerId, userId, userToken);
});
});
</script>
Comments
Post a Comment