I've finally discovered the url form from which, i'm nearly done :-)

might help to some other amateurs like myself, so reposting: 
http://picasaweb.googl.com/data/feed/base/user/112391172997417047399?&kind=album&hl=en_US&fields=entry(title,gphoto:numphotos,media:group(media:thumbnail))

Adam.


Dne pátek, 30. března 2012 10:35:32 UTC+2 Adam Perutka napsal(a):
>
> Hallo everybody, 
> I'm new to google API and because I need just 1 very simple function, I 
> don't intend to become a PRO in it. 
> At the same time, I'm just lame PHP programmer. 
>
> I need to do one really simple PHP function:
>
> string albumcover ($userID, $albumName, $size) 
> -* returns URL of the of album cover photo *
>
> real-life example:
> $userid: 112391172997417047399
> $albumName: 65GiottosMT7350
> $size: 100
> *shall return*: 
> https://lh4.googleusercontent.com/-As7VXqY168Y/T3TbXJnk5-E/AAAAAAAAAVU/dqI6VXtDrOk/s100-c/65GiottosMT7350.jpg
>
>
> I want to do it by the simpliest possible way, because I'll be fetching it 
> for about 100albums for each pageview an a page that has *10thousands+ 
> pagewiews per day*. (is it a good idea, shouldn't I cache the results 
> into the database? (to relief both servers?)
>
> Can anybody help me write the function? I tried myself, but waded further 
> deep into the google api, then I'd like. 
> What i discovered: 
> 1. I'll have to fetch some feed like: 
> *
> https://picasaweb.google.com/data/feed/base/user/112391172997417047399?alt=rss&kind=album&hl=cs&imgmax=1600
> *
> with *parameter fields* set to *media:thumbnail *only (how exactly do I 
> type this condition into the field?)  - this is important, so that thse 
> result is *as small as possible*. *
> *
> 3. find the apropriate album by it's name (e.g.  65GiottosMT7350) or it's 
> *albumID* (=don't know how to get it, I have only the name).  
> 4. retrieve the url by some PHP XML function
> 5. change the size of the thumbnail in the result to required size, eg in: 
> https://lh4.googleusercontent.com/-As7VXqY168Y/T3TbXJnk5-E/AAAAAAAAAVU/dqI6VXtDrOk/s160-c/65GiottosMT7350.jpg
> change the part "s160-c" to "s100-c" - this is the easiest part :-)
>
> baisically if you help me with the steps nr. 1 and 2 that shall be enough 
> for me. 
>
>
> or maybe and *idea for even much simpler function:  *
> from $albumname  (eg:  65GiottosMT7350) 
> it returns the* strange string *in the middle of the desired url (eg.  *
> /-As7VXqY168Y/T3TbXJnk5-E/AAAAAAAAAVU/dqI6VXtDrOk/ *)*
> *
> - any way how to easily retrieve this strange string? 
>
>
> can anybody please help me? I know i'm near, but still cannot pull it 
> there...
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Picasa Web Albums API" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-picasa-data-api/-/djvCVrT2xEgJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-picasa-data-api?hl=en.

Reply via email to