Created
December 5, 2011 13:54
-
-
Save nils-werner/1433648 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<navigation> | |
<page handle="startseite" id="88"> | |
<name>Startseite</name> | |
<types> | |
<type>hidden</type> | |
<type>index</type> | |
</types> | |
</page> | |
<page handle="referenzen" id="78"> | |
<name>Referenzen</name> | |
<page handle="person" id="96"> | |
<name>Referenzen von Person</name> | |
<types> | |
<type>hidden</type> | |
</types> | |
</page> | |
<page handle="xml" id="94"> | |
<name>XML</name> | |
<types> | |
<type>hidden</type> | |
<type>XML</type> | |
</types> | |
</page> | |
</page> | |
<page handle="philosophie" id="87"> | |
<name>Philosophie</name> | |
</page> | |
<page handle="loesungen" id="89"> | |
<name>Lösungen</name> | |
</page> | |
<page handle="team" id="79"> | |
<name>Team</name> | |
</page> | |
<page handle="impressum" id="93"> | |
<name>Impressum</name> | |
<types> | |
<type>hidden</type> | |
</types> | |
</page> | |
<page handle="wartung" id="75"> | |
<name>Wartungsarbeiten</name> | |
<types> | |
<type>hidden</type> | |
<type>maintenance</type> | |
</types> | |
</page> | |
<page handle="404-page-not-found" id="76"> | |
<name>404: Page Not Found</name> | |
<types> | |
<type>404</type> | |
<type>hidden</type> | |
</types> | |
</page> | |
<page handle="feed" id="98"> | |
<name>Interner Feed</name> | |
<types> | |
<type>hidden</type> | |
<type>XML</type> | |
</types> | |
</page> | |
</navigation> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<xsl:stylesheet version="1.0" | |
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | |
xmlns:atom="http://www.w3.org/2005/Atom" | |
exclude-result-prefixes="atom"> | |
<xsl:template match="/"> | |
<xsl:apply-templates select="navigation/page[@id = '94']" mode="url"/> | |
</xsl:template> | |
<xsl:template match="page" mode="url"> | |
<xsl:value-of select="concat('root','/',@handle,'/')"/> | |
</xsl:template> | |
<xsl:template match="page/page" mode="url"> | |
<xsl:apply-templates select="parent::page" mode="url"/> | |
<xsl:value-of select="concat(@handle,'/')"/> | |
</xsl:template> | |
</xsl:stylesheet> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment