Abstract

Filip recently asked if it was possible to show private albums in a picasa-feed, to use with the PicasaViewer script. Good questi0n, and at the same time I needed it myself. Lucky Filip ;-)

Quick start

The direct link to the PHP-script you need: privateFeed.phps.

Short instructions:

  • edit lines 53 – 55 to your values
  • create a file called PicasaAuth.php (or whatever you set in line 53) and CHMOD it to 666
  • replace line 30 in picasaViewer.js with the following:
 
var url = (Browser.getQueryStringValue('albumid')) ? 'privateFeed.php?albumid='+ Browser.getQueryStringValue('albumid') +'&category=photo&alt=json&callback=viewPhotoList&thumbsize=' + thumbsize +'&imgmax='+imgmax : 'privateFeed.php?category=album&alt=json&callback=viewAlbumList&thumbsize=' + thumbsize;

That’s it!

Some explanation

The private-feed script uses curl to authenticate at the google systems. It takes abit of time to do that, but luckily the auth-token you recieve is valid for 24 hours. That means you don’t have to authenticate on every request. Ofcourse you need to store the key somewhere: that is where we use PicasaAuth.php.

In the picasa reference guide you find a few parameters to request a feed. You can use these parameters when calling the private feed script: it passes them through.