简体   繁体   English

仅使用代码将动态 Instagram 提要嵌入 HTML(无 API/插件)

[英]Embed Dynamic Instagram Feed Into HTML With Code Only (NO API/Plugin)

I am looking to get started on how to embed an entire dynamic Instagram feed using HTML and JavaScript (if possible/if necessary) instead of using API's and plugins.我希望开始学习如何使用 HTML 和 JavaScript(如果可能/如果需要)而不是使用 API 和插件来嵌入整个动态 Instagram 提要。

Essentially, what I want on a page for a website that I am currently working on is to show all of the posts as part of a feed on a website and whenever a new post is uploaded on Instagram, that newest post to load automatically.本质上,我想要在我目前正在处理的网站的页面上显示所有帖子作为网站上提要的一部分,并且每当在 Instagram 上上传新帖子时,自动加载最新帖子。

Does anyone know how to do this or how I can get started on this please?有谁知道如何做到这一点,或者我该如何开始呢?

A little late to reply, but hopefully this is helpful for someone...回复有点晚了,但希望这对某人有帮助......

Firstly, so we're on the same page, you WILL need to use at least one API to do this-- the Instagram API.首先,我们在同一页面上,您将需要至少使用一个 API 来执行此操作——Instagram API。 You need to use the Instagram API in order to fetch content from their service (this article explains the basic idea https://www.freecodecamp.org/news/what-is-an-api-in-english-please-b880a3214a82/ )您需要使用 Instagram API 才能从他们的服务中获取内容(本文解释了基本思想https://www.freecodecamp.org/news/what-is-an-api-in-english-please-b880a3214a82/ )

Now, you do not say whether you've looked at the Instagram developer docs, but this would be a great place to start: https://developers.facebook.com/docs/instagram现在,您不会说您是否查看过 Instagram 开发人员文档,但这将是一个很好的起点: https://developers.facebook.com/docs/instagram

It looks like they have some example code and tutorials, so hopefully there is enough info here to get you started, Based on your question: it sounds like you may want to first check out their BasicDisplayAPI: https://developers.facebook.com/docs/instagram-basic-display-api看起来他们有一些示例代码和教程,所以希望这里有足够的信息可以帮助您入门,根据您的问题:听起来您可能想先查看他们的 BasicDisplayAPI: https://developers.facebook.com /docs/instagram-basic-display-api

Finally, you might find this other SO post helpful.最后,您可能会发现此其他 SO 帖子很有帮助。 Unfortunately the blog link is broken, but the code snippet looks promising Embed an instagram feed不幸的是,博客链接已损坏,但代码片段看起来很有希望嵌入 instagram 提要

This blog article looks promising as well: https://dev.to/ljcdev/embedding-an-instagram-post-in-your-website-3666这篇博客文章看起来也很有希望: https://dev.to/ljcdev/embedding-an-instagram-post-in-your-website-3666

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM