Serving the Florida .NET Developer Communities (a Joe Healy production)
CodeProject Windows 7 Contest

spaces.live.com as am embeddable photo source
Posted on 8/9/2007 10:26:12 PM

david hayden, jim wooley, jim zimmerman tampa codecamp photo linked from spaces.live.com

tampa codecamp photo linked from spaces.live.com

How to link to a spaces.live.com photo

There are a ton of photo sites out there. Flickr is the obvious. Spaces.live.com also has a very good photo gallery, but I wanted to actually link photos from spaces into my blog here at the fish. Not 100% clear how to do that. After a few emails with the product guys, I learned how you can build some perma-urls to photos at spaces.live.com. In the spirit of Jon Box, I'm now passing my learnings along to you.

First locate your photo blog albumn ID. The format is: You can start by using the Photos All Albums feed to get an album ID

http://<alias>.spaces.live.com/photos/feed.rss

For my photos I'm using 'thedevfish' space (basically all photos), so my feed is:
http://thedevfish.spaces.live.com/photos/feed.rss

The album I want is my "influential photos" album. By clicking on the album I can see its URL, which contains the album id. The URL is http://thedevfish.spaces.live.com/photos/cns!75364D9E73295107!275/ . The album id is the part between cns! and the closing slash:

http://thedevfish.spaces.live.com/photos/cns!75364D9E73295107!275/

So in this case my album id is 75364D9E73295107!275

Next I want an RSS with ALL the photos in an album. The format for the URL is:

http://thedevfish.spaces.live.com/photos/cns!<ID>/feed.rss

So to get to my influentials album I need to get go to the following URL: http://thedevfish.spaces.live.com/photos/cns!75364D9E73295107!275/feed.rss

Inside the RSS you will see all the photos listed. The little paper clip icon at the bottom right gives you a permalink to the photo. So for David 'the great one' Hayden, we get a url of:

http://storage.live.com/items/75364D9E73295107!276 

We can then use the SRC property of an image tag to link to the photo and use it in a page

<img src="http://storage.live.com/items/75364D9E73295107!276" />

There are some interesting ideas I can work towards on this api. I'd like to see:
o link to thumbnails also (its there in the URLs with view source but not documented
o some kind of powertoy for getting a single photo url
o powertoy for building filmstrips that display via ajax and silverlight
o automatic film stripper for a photo albumn (no build necessary) ajax and silverlight
o rip apart the vista sidebar gadget and add in rips of spaces feeds
Watch devfish for more info. If I get those projects cooked I'll post the source.

links: 
spaces.live.com RSS photo feed documentation :: http://msdn2.microsoft.com/en-us/library/bb447744.aspx
catherine heller blog :: http://blogs.msdn.com/cheller/
john bruno blog (a florida guy!) :: http://jpbruno.spaces.live.com/



The opinions expressed on this website are Joe Healy's and Joe Healy's alone, and have nothing whatsoever to do with my employers views of the world Applied Innovations
Hosted by Applied Innovations
devfish v2010_35fw:3.0