Thursday, January 17, 2008

Picasa: Download Web Albums in Firefox or Opera

Update of this post taking care of new Picasa release is explained at http://sandyiit.blogspot.com/2008/09/picasa-30-download-web-albums-in.html

I am slowly turning into a google consumer. When I first ventured into the world wide web, it was dominated by Yahoo. I used Yahoo search and later moved to google search. I used Yahoo mail which I later switched to gmail. I user Yahoo messenger and later switched to GTalk. I used Yahoo pics and also Flickr. I liked flickr but its 200 pics limit was something which irritated me. So when I saw picasa giving a Gig of space for my pics I moved to it. So I am moving out of Yahoo's fold to Google's. Its not that Yahoo is bad but they make things heavy and bloated. Google keeps it simple and tidy which I like and hence so many changes.

Photos is one service where I still love flickr compared to picasa but I still use picasa because of it 1 Gig space and also its desktop application which lets you do quite a lot of things. Still it has its impairments. In my last post I talked about caption, now its time for downloading whole web albums present in picasa web.

Picasa has its own protocol picasa:// to download and upload pictures from desktop to the web. Ideally when you install picasa on your desktop, this protocol should get registered to your web browser which should tell the browser that if such a link appears what to do which is to launch picasa. Sadly only IE seems to understand it and work as expected. Neither Firefox nor Opera seems to understand the protocol and hence it shows a "Download Picasa" link
in the left navigation menu when Picasa is already installed on the desktop. Now how can we
download the whole album?

To do so, just view the source of the page. Do a right click + View Page Source in case of Firefox of press CTRL + F3 in case of opera. Now in the HTML source search for the string picasa://.

Now you will get a statment which looks like:

picasa://downloadfeed/?url=http%3A%2F%2Fpicasaweb.google.com%2Fdata%2Ffeed%2Fback_compat%2Fuser%2Fsandyiit%2Falbumid%2F5152729459149591681%3Fkind%3Dphoto%26alt%3Drss%26imgdl%3D1


This is the download url based on the picasa:// protocol. Now how do you use it to download the album. Simple, just open the command window type in:

> c:\Program Files\Picasa2\Picasa2.exe _url_

The _url_ is the picasa:// url which we got above. When you do so, you will picasa launching itself and loading the web album and asking you whether you want to download it or not. Do it and you have the album at your desktop and the work is done :)

Monday, January 7, 2008

Picasa: Adding File Names to Caption

Update of this post is available at http://sandyiit.blogspot.com/2008/10/picasa-adding-file-names-to-caption.html

I used to save my pictures in photos@yahoo then moved to flickr. Flickr was good but had a limit of 200 pics per account. So had to move on to the google belt and started using picasa. There was 1 GB up for grabs so I started uploading my pictures to it.

I faced a problem. Normally when I transferred my pictures from my camera to my laptop, I got names like Picture 001.jpg, Picture 002.jpg. So I renamed them to names like 001. The start.jpg which conveyed more information and added to its memory value. Then I uploaded them to picasa to see that none to the names appear in there. Picasa uses IPTC tags to display captions.

Searching in the net, I found the tag was Iptc.Application2.Caption and this post provides nice information to set the captions equal to your filenames but the script

FOR %%c in (*.jpg) DO exiv2 -k -M"add Iptc.Application2.Caption %%c" "%%c"

has a issue. It takes filenames hence appends the extension .JPG to the caption too. Next it tries to add the IPTC tag which if already set, new caption can't be added. We need to force it or simply overwrite it. So I changed the script to

FOR %%c in (*.jpg) DO exiv2 -k -M"set Iptc.Application2.Caption %%~nc" "%%c"

This now sets hence overwrites the Caption tag and also takes the filename without the extension as the caption and thats what I wanted.

P.S: I got a comment:

Barun said...
Sonique/ Sandeep- I tried running the command given by sunil25125 by extracting exiv2-o.18 and making the nmtocap.dat, both in the same directory as my jpg files. But when I double click on the .dat file, I get following errors for each file:
Failed to Open the File

Any way out?

Thanks


And the answer is.

Windows shell might see some problems with the above script specifically the variable declared as %%c. Please try %c is that case specially when you get "Failed to Open the File" . So the script for you will be:

FOR %c in (*.jpg) DO exiv2.exe -k -M"set Iptc.Application2.Caption %~nc" "%c"