how to obtain actual urls for all images in a google picasa web album

可紊 提交于 2019-12-07 11:30:27
Robert Rowntree

you will need to use the picasa api with your 'userID' and the 'albumID'...

read picasa api to find out how to get those values... then

have a look at my answer here

that answer was for slightly different xslt expression applied to the 'fields=' part of the gdata request.

you want all the entries for the feed of the album... then within each entry you want the equivalent json of:

"entry": ["media$group":{ "media$content":[ { "url"

So, when u figure out the oauth playground explained in the other answer, after you authenticate to "Picasa" service, you can simply ask for this request string substituting for your (userID, albumID) :

/feed/api/user/rowntreerob/albumid/5682316071017984417?fields=entry%2Fmedia%3Agroup%2Fmedia%3Acontent%5B%40url%5D&alt=json

and use the Json parser to display your results , an excerpt of the first couple of pictures that u see below:

{ "version":"1.0", "encoding":"UTF-8", "feed":{ "xmlns":"http://www.w3.org/2005/Atom", "xmlns$gphoto":"http://schemas.google.com/photos/2007", "xmlns$media":"http://search.yahoo.com/mrss/", "entry":[ { "media$group":{ "media$content":[ { "url":"https://lh3.googleusercontent.com/-_FFMNGPU1TQ/TtukXyN4eCI/AAAAAAAACso/EzPmut2iKVQ/DSC01612.JPG", "height":512, "width":341, "type":"image/jpeg", "medium":"image" } ] } }, { "media$group":{ "media$content":[ { "url":"https://lh3.googleusercontent.com/-MhKoWh5MMxE/TtukZNnPvJI/AAAAAAAACkk/oz5fxA6qHx4/DSC01613.JPG", "height":512, "width":341, "type":"image/jpeg", "medium":"image" } ] } }, { "media$group":{ "media$content":[ { "url":"https://lh4.googleusercontent.com/-Bg9L7Cggfak/TtukZ0BtRiI/AAAAAAAACk0/2HiJtkEFUss/DSC01614.JPG", "height":512, "width":341, "type":"image/jpeg", "medium":"image" } ] } }, { "media$group":{ "media$content":[ { "url":"https://lh3.googleusercontent.com/-u-kqaskIfqc/TtukajDNYHI/AAAAAAAACk8/3jo9wS-zhbA/DSC01615.JPG", "height":512, "width":341, "type":"image/jpeg", "medium":"image" } ] } }, { "media$group":{ "media$content":[ { "url":"https://lh3.googleusercontent.com/-9OoGQKTh7CQ/Ttukh1ocOCI/AAAAAAAACgQ/fKy-0Ru7J4M/DSC01624.JPG", "height":512, "width":341, "type":"image/jpeg", "medium":"image" } ] } },

the pictures that u want are in the "url" attribute...

Using Firefox, a Greasemonkey script can be used that provides the actual link to some/all images in a Picasa album.

You need to navigate to the album's page in firefox, at the top the extension displays options- eg if you want urls for images of a specific size, or for some images only-- once these options are filled in you can easily obtain the link(s).

The greasemonkey script I used is at http://www.userscripts.org (Disclaimer- use such a script after ensuring that it is not malicious).

There are many such scripts (for obtaining links to images in a picasa album) at http://www.userscripts.org- just do a search and you will get a list of such scripts.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!