简体   繁体   English

Instagram使用php,curl或json喜欢照片

[英]Instagram liking a photo using php, curl or json

I'm writing an instagram web app and i'm looking at Instagrams developer details and I'm at a stage where I'm stuck. 我正在编写一个instagram网络应用程序,并且正在查看Instagram开发人员的详细信息,而我正处于一个陷于困境的阶段。

I am using json to retrieve images for my feed, I've managed to log into my instagram app. 我正在使用json检索供稿的图像,我已经成功登录到instagram应用。

Now what I'd like to do is be able to view images and 'like' them. 现在我想做的就是能够查看图像并“喜欢”它们。 Instagram only seem to show me the following details Instagram似乎只向我显示以下详细信息

curl -F 'access_token=11208672.f59def8.d78b9193a13d4e79a5bdb985ce73831d' \
    https://api.instagram.com/v1/media/{media-id}/likes

Could someone assist in helping me out understanding how to Like an instagram image or convert the above to post using json/php 有人可以帮助我了解如何喜欢instagram图像或将上述内容转换为使用json / php发布的内容

Maybe you could use the Instagram-PHP-API wrapper. 也许您可以使用Instagram-PHP-API包装器。
You can find an example of how to 'like' an image on this page . 您可以在此页面上找到如何“喜欢”图像的示例。
Have also a look at the _makeCall method of the Instagram class for an example of how to make an API call using the PHP cURL functions and parse the json response. 还可以查看Instagram类_makeCall方法,以获取有关如何使用PHP cURL函数进行API调用以及解析json响应的示例。

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

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