picasa:list-photos

Purpose

Retrieves images from Google Picasa® web albums.

Contained by

Attributes

Attribute Description Type Default Options Use
album The name of the user's album to be displayed. It is an error if this is specified without also specifying the user-id attribute, or if both this and the album-id attribute is specified. xs:string     optional 
album-id ID of the user's album to be displayed. It is an error if this is specified without also specifying the user-id attribute, or if both this and the album attribute is specified. xs:string     optional 
page-index An optional number of the page to return in the response. It is not an error if the value of this attribute is greater than the actual number of pages, in that case an empty response is returned. xs:integer [1,∞]  optional 
page-size An optional number of images returned in a single response page. It is an error if the value is outside the range. xs:integer 10  [1,500]  optional 
photo-id Identifies the individual photo. album or album-id must also be specified. xs:string     optional 
query An optional query string. If specified, then only the photos that contain the same string in either their title, or one of their tags will be returned. The matching is case insensitive. xs:string     optional 
tags Contains space separated set of tags. If specified, then only the images that have all these tags associated with them will be returned. xs:string     optional 
user-id Displays images or albums that belong to the selected user. If this attribute is not specified, then all photos on Picasa will be searched. xs:string     optional 

Examples

<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/2002/06/xhtml2"
  xmlns:pipeline="http://www.volantis.com/xmlns/marlin-pipeline"
  xmlns:picasa="http://www.volantis.com/xmlns/2008/08/picasa">
  <head>
    <title>Picasa album by id</title>
  </head>
  <body>
    <pipeline:transform href="picasa2xdime.xsl">
      <picasa:list-photos user-id="testvolantis" album-id="5240956067202995025"/>
    </pipeline:transform>
  </body>
</html>

Picasa returns requested data in the form of a feed. You must use an XSL transform to convert the feed to an XDIME presentation markup.

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns="http://www.w3.org/2002/06/xhtml2"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:atom="http://www.w3.org/2005/Atom"
  xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/"
  xmlns:exif="http://schemas.google.com/photos/exif/2007"
  xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
  xmlns:gml="http://www.opengis.net/gml"
  xmlns:georss="http://www.georss.org/georss"
  xmlns:photo="http://www.pheed.com/pheed/"
  xmlns:media="http://search.yahoo.com/mrss/"
  xmlns:batch="http://schemas.google.com/gdata/batch"
  xmlns:gphoto="http://schemas.google.com/photos/2007">
  <xsl:template match="atom:feed">
    <h1>
      <xsl:value-of select="atom:title"/>
    </h1>
    <xsl:for-each select="atom:entry">
      <div>
        <object>
          <xsl:attribute name="src">
            <xsl:value-of select="atom:content/@src"/>
          </xsl:attribute>
          <xsl:attribute name="srctype">
            <xsl:value-of select="atom:content/@type"/>
          </xsl:attribute>
          <param name="mcs-external-label">
            <xsl:attribute name="value">
              <xsl:value-of select="atom:title"/>
            </xsl:attribute>
          </param>
        </object>
      </div>
    </xsl:for-each>
  </xsl:template>
</xsl:stylesheet>

Related topics