Instagram API显示太多图像

时间:2015-11-02 12:46:25

标签: javascript html instagram instagram-api

我对Instagram API有疑问。我只想显示上传到我帐户的最后一张图片,但现在显示所有图片:

<div class="col-xs-12 col-sm-6 col-md-4">
    <div class='square'>
        <div id="slideshow" class='white instagram' style="margin-top: 0; margin-bottom: 0; margin-left: 0; margin-right: 0;"></div>
            <h5>Instagram</h5>
            <h4>does</h4></br/>
                <div class="bottom"><i class="fa fa-instagram fa-2x"></i></div>
                <div class='bottom_right'>
                    Wed 18 Oct 2015
               </div>
       </div>
   </div>
</div>

<script type="text/javascript">
        $(document).ready(function() {
            $('#slideshow').embedagram({
                    instagram_id: xxxxxxxxx,
                    thumb_width: 360,
                    wrap_tag: 'div'
                });
        });
</script>

1 个答案:

答案 0 :(得分:1)

limit有一个embedagram参数。默认情况下是20。

$('#slideshow').embedagram({
                    instagram_id: xxxxxxxxx,
                    thumb_width: 360,
                    wrap_tag: 'div',
                    limit: 5
                });
        });