Picasa web album integration UPDATE

I have rewritten some of the code of my Picasa Web Album javascript.
(originally from Haochi Chen at http://googlified.com)
The first version was a success but it still lacked some features that I wanted.
I’ve since improved the code. It now makes use of the JSon API data, where it originally used the JSon BASE data from the GData Api.

Changelog, download and help at the end of this post, so keep reading…
And visit my Photo Gallery v2 to see what I mean.

Implementing this script on your site.

Step 1.
Download pwa2.js here

Upload the pwa2.js to the root or a subdirectory of your site.
Make sure you set the correct paths of the js src attributes in step 2 when placed in a subdirectory.

Step 2.
Include the following html code in your page:

<script type="text/javascript">
username = 'your.username';
</script>
<script type="text/javascript" src="/pwa2.js"></script>

Step 3.
Set the correct value of the variable username.
The username is the picasa webalbum gallery name that can be found in the picasa webalbum settings menu under gallery-URL, which is most of the time the same as the username.

You should be good to go.

Step 4. (optional)
You can further personalize this script by changing the number of rows and columns you want to see in the pwa2.js at line 3 and 4. The number of rows is defined by the maxreslts / cols.
Photo size and Thumb size can be changed at line 2 (photosize) and 3 (thumbsize).
Keep in mind that the API of google doesn’t support a lot of different sizes, to create a certain thumbsize that google can’t return, you might have to use browser scaling on your images which doesn’t do any good to the quality.

Changelog pwa.js for my v1.5 to v2.0:

- renamed to pwa2.js for ease keeping versions apart
- Added date/time to albums and pictures in albums
- Added Exif block to photo page
- Fixed broken paging
- Added description to album page
- Added location to album page
- Removed watermark for simplicity and it wasn’t really necessary
- Fixed page parameter for Simple PHP Blog integration, no need for editing code or enforced naming of the page, thus making it fully SPHPBlog compatible!
- A lot more I can’t remember right now…

Popularity: 10% [?]

Other posts

Comments are closed.