1.1 --- a/build.xml Sun Apr 03 16:34:42 2011 +0200
1.2 +++ b/build.xml Sun Apr 03 16:51:06 2011 +0200
1.3 @@ -21,14 +21,15 @@
1.4 </target>
1.5
1.6 <target name="agregace" description="Vytvoří agregované výstupy: RSS, Atom, Sitemap.xml">
1.7 + <!-- Atom -->
1.8 <xslt in="${vstup}/web.conf" out="${výstup}/atom.xml" style="${šablona}/atom.xsl">
1.9 - <param name="konfigurák" expression="../vstup/web.conf"/>
1.10 <classpath location="/usr/share/java/saxonb-9.0.jar"/>
1.11 <classpath location="${funkce}"/>
1.12 <factory name="net.sf.saxon.TransformerFactoryImpl">
1.13 <attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>
1.14 </factory>
1.15 - </xslt>
1.16 + </xslt>
1.17 +
1.18 </target>
1.19
1.20 <target name="kompiluj-funkce" description="">
2.1 --- a/šablona/atom.xsl Sun Apr 03 16:34:42 2011 +0200
2.2 +++ b/šablona/atom.xsl Sun Apr 03 16:51:06 2011 +0200
2.3 @@ -8,24 +8,21 @@
2.4 exclude-result-prefixes="fn g j">
2.5 <xsl:output method="xml" indent="yes" encoding="UTF-8"/>
2.6
2.7 - <xsl:param name="konfigurák"></xsl:param>
2.8 -
2.9 - <xsl:template match="/">
2.10 - <!-- TODO: proměnná: -->
2.11 - <xsl:variable name="konfigurace" select="document($konfigurák)"/>
2.12 + <xsl:template match="/">
2.13
2.14 <feed>
2.15 - <title><xsl:value-of select="$konfigurace/g:web/g:název"/></title>
2.16 - <subtitle><xsl:value-of select="$konfigurace/g:web/g:podtitul"/></subtitle>
2.17 - <link rel="self" href="{concat($konfigurace/g:web/g:url, 'atom.xml')}"/>
2.18 - <link href="{$konfigurace/g:web/g:url}"/>
2.19 + <title><xsl:value-of select="g:web/g:název"/></title>
2.20 + <subtitle><xsl:value-of select="g:web/g:podtitul"/></subtitle>
2.21 + <link rel="self" href="{concat(g:web/g:url, 'atom.xml')}"/>
2.22 + <link href="{g:web/g:url}"/>
2.23 <updated><xsl:value-of select="current-dateTime()"/></updated>
2.24 <author>
2.25 - <name><xsl:value-of select="$konfigurace/g:web/g:autor/g:jméno"/></name>
2.26 - <email><xsl:value-of select="$konfigurace/g:web/g:autor/g:email"/></email>
2.27 + <name><xsl:value-of select="g:web/g:autor/g:jméno"/></name>
2.28 + <email><xsl:value-of select="g:web/g:autor/g:email"/></email>
2.29 </author>
2.30 - <id><xsl:value-of select="concat('urn:uuid:', $konfigurace/g:web/g:uuid)"/></id>
2.31 + <id><xsl:value-of select="concat('urn:uuid:', g:web/g:uuid)"/></id>
2.32
2.33 + <xsl:variable name="konfigurace" select="/"/>
2.34 <xsl:for-each select="collection('../vstup/?select=*.xml')[empty(g:stránka/g:skrytá) or not(g:stránka/g:skrytá)]">
2.35 <entry>
2.36 <title><xsl:value-of select="g:stránka/g:nadpis"/></title>