提取instagram照片并上传到我的域


Pull instagram photos and upload to my domain?

我想让一个cronjob或类似的程序运行一个脚本,将我的instagram照片拉到我域上的文件夹中。有人做过这样的事吗?有点像Instaport,但它在我的网站上自动了吗?

我登录了instagram上的开发区,查看了一些选项,但在API上迷失了方向。我对API没有做太多的工作。

如有任何想法或帮助,我们将不胜感激。

这里有一个我曾经使用过的快速而肮脏的解决方案:

使用API从Instagram获取所有照片:有一些php类可以使用,例如:http://www.9lessons.info/2012/05/login-with-instagram-php.html

获取所有图像的URL

制作一个脚本,将这些内容存储在服务器上的文件夹中。你可以使用类似的东西

$path_parts = pathinfo($url); // Return info about the URL
$image = ($path_parts['basename']); // Save file name in a variable
mkdir("folderName/", 0700); // Create the folder
copy($url,"folderName/".$image); // Copy files to folder

希望这能有所帮助!