Skip to content

Instantly share code, notes, and snippets.

@markahesketh
Created June 28, 2012 09:06
Show Gist options
  • Save markahesketh/3010086 to your computer and use it in GitHub Desktop.
Save markahesketh/3010086 to your computer and use it in GitHub Desktop.
<data>
<portfolio-collaborations>
<section id="2" handle="collaborations">Collaborations</section>
<entry id="454">
<title handle="test-collaboration">Test collaboration</title>
<images>
<item>
<file size="75 KB" path="/img/collaborations" type="image/jpeg">
<filename>Agate-Necklace-by-The-Vamoose-001.jpg</filename>
</file>
</item>
<item>
<file size="87 KB" path="/img/collaborations" type="image/jpeg">
<filename>Agate-Slice-Necklaces-by-The-Vamoose-001.jpg</filename>
</file>
</item>
<item>
<file size="226 KB" path="/img/collaborations" type="image/jpeg">
<filename>A-Collection-by-The-Vamoose-001.jpg</filename>
</file>
</item>
<item>
<file size="125 KB" path="/img/collaborations" type="image/jpeg">
<filename>Agate-Suede-and-Layered-Metal-Necklace-by-The-Vamoose-001.jpg</filename>
</file>
</item>
<item>
<file size="68 KB" path="/img/collaborations" type="image/jpeg">
<filename>Acorn-Charm-and-Silk-Cord-Necklace-by-The-Vamoose-001.jpg</filename>
</file>
</item>
</images>
<position handle="10">10</position>
</entry>
</portfolio-collaborations>
<portfolio-gallery>
<section id="1" handle="images">Images</section>
<entry id="456">
<image size="226 KB" path="/img/gallery" type="image/jpeg">
<filename>a-collection-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="465">
<image size="141 KB" path="/img/gallery" type="image/jpeg">
<filename>body-chain-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="466">
<image size="65 KB" path="/img/gallery" type="image/jpeg">
<filename>bracelets-by-the-vamoose-photography-by-eefje-de-coninck-001.jpg</filename>
</image>
</entry>
<entry id="461">
<image size="122 KB" path="/img/gallery" type="image/jpeg">
<filename>amazonite-and-metal-necklace-by-the-vamoose-photography-by-eefje-de-coninck-001.jpg</filename>
</image>
</entry>
<entry id="467">
<image size="156 KB" path="/img/gallery" type="image/jpeg">
<filename>braided-rope-and-metal-bead-necklace-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="464">
<image size="86 KB" path="/img/gallery" type="image/jpeg">
<filename>amethyst-necklaces-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="460">
<image size="125 KB" path="/img/gallery" type="image/jpeg">
<filename>agate-suede-and-layered-metal-necklace-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="470">
<image size="105 KB" path="/img/gallery" type="image/jpeg">
<filename>brass-and-gemstone-jewellery-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="468">
<image size="60 KB" path="/img/gallery" type="image/jpeg">
<filename>brass-and-gemstone-bracelet-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="459">
<image size="87 KB" path="/img/gallery" type="image/jpeg">
<filename>agate-slice-necklaces-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="457">
<image size="68 KB" path="/img/gallery" type="image/jpeg">
<filename>acorn-charm-and-silk-cord-necklace-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="458">
<image size="75 KB" path="/img/gallery" type="image/jpeg">
<filename>agate-necklace-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="455">
<image size="226 KB" path="/img/gallery" type="image/jpeg">
<filename>a-collection-inspiration-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="462">
<image size="44 KB" path="/img/gallery" type="image/jpeg">
<filename>amazonite-and-metal-necklace-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="469">
<image size="155 KB" path="/img/gallery" type="image/jpeg">
<filename>brass-and-gemstone-bracelets-by-the-vamoose-001.jpg</filename>
</image>
</entry>
<entry id="463">
<image size="78 KB" path="/img/gallery" type="image/jpeg">
<filename>amethyst-and-leather-bracelet-by-the-vamoose-001.jpg</filename>
</image>
</entry>
</portfolio-gallery>
</data>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="xml" indent="yes" />
<xsl:template match="data">
<ul>
<xsl:apply-templates select="portfolio-gallery/entry"/>
</ul>
</xsl:template>
<xsl:template match="portfolio-gallery/entry">
<xsl:param name="position"><xsl:number /></xsl:param>
<li><img src="/image/gridsmall/img/gallery/{image/filename}" width="150" height="150"/></li>
<xsl:apply-templates select="../../portfolio-collaborations/entry[position = $position]"/>
</xsl:template>
<xsl:template match="portfolio-collaborations/entry">
<li class="big"><img src="/image/gridbig/img/collaborations/{images/item[1]/file/filename}" width="510" height="330"/></li>
</xsl:template>
</xsl:stylesheet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment