从本地主机调用 Instagram API [英] Call Instagram API from localhost

查看:20
本文介绍了从本地主机调用 Instagram API的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以通过 API 从 localhost 获取 INSTAGRAM 用户详细信息?

Is it possible to get INSTAGRAM user details through API from localhost ?

因为我试图从本地主机执行此操作但无法获取信息.单击登录 url 后,它会将我重定向到 INSTAGRAM,成功登录并授权应用程序后,它会在我的回调 URL 中使用代码正确重定向我.但是当我尝试使用访问令牌获取信息 (cURL) 时,它返回 null.

Because I am trying to doing this from localhost but unable to fetch the information. After click the login url it redirect me to the INSTAGRAM and after successfully login and authorize the apps it redirect me properly in my callback URL with code. But when I am trying to fetch the info (cURL) using access token then it return null.

但相同的代码在实时运行时完美运行.

But same code run perfectly in live.

推荐答案

最终我解决了这个问题.现在我可以连接到 Instagram.

Ultimately I resolved the problem. now I am able to connect to Instagram.

我使用 Ian Luckraft 的 CodeIgniter Instagram 库.在配置文件中,我只是更改了

I use the CodeIgniter Instagram Library by Ian Luckraft. In config file I just change the

$config['instagram_ssl_verify'] = FALSE;

默认情况下它是TRUE.

这篇关于从本地主机调用 Instagram API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆