2007-10-26 17:42:03 +00:00
|
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
2007-10-09 15:58:37 +00:00
|
|
|
<xsl:stylesheet version="1.0"
|
|
|
|
xmlns="http://www.w3.org/1999/xhtml"
|
|
|
|
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
|
|
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
|
|
xmlns:cc="http://web.resource.org/cc/"
|
|
|
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
|
|
>
|
|
|
|
|
|
|
|
<xsl:output
|
|
|
|
doctype-public="-//W3C//DTD XHTML 1.1//EN"
|
|
|
|
doctype-system="http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"
|
2007-10-26 17:42:03 +00:00
|
|
|
encoding="UTF-8"
|
2007-10-09 15:58:37 +00:00
|
|
|
indent="yes"
|
|
|
|
method="xml"
|
|
|
|
media-type="application/xhtml+xml"
|
|
|
|
omit-xml-declaration="no"
|
|
|
|
/>
|
|
|
|
|
2007-11-22 05:21:17 +00:00
|
|
|
<xsl:include href="./xhtml/frontpage.xsl"/>
|
|
|
|
<xsl:include href="./xhtml/loginform.xsl"/>
|
|
|
|
<xsl:include href="./xhtml/results.xsl"/>
|
|
|
|
<xsl:include href="./xhtml/upload.xsl"/>
|
|
|
|
<xsl:include href="./xhtml/video.xsl"/>
|
2007-11-26 14:25:31 +00:00
|
|
|
<xsl:include href="./xhtml/register.xsl"/>
|
2007-12-19 23:12:39 +00:00
|
|
|
<xsl:include href="./xhtml/settings.xsl"/>
|
2007-12-27 14:50:08 +00:00
|
|
|
<xsl:include href="./xhtml/advancedsearch.xsl"/>
|
2007-10-28 03:06:45 +00:00
|
|
|
|
2007-11-02 12:39:25 +00:00
|
|
|
<xsl:variable name="locale">
|
|
|
|
<xsl:choose>
|
2007-11-02 13:04:27 +00:00
|
|
|
<xsl:when test="document(concat('../locale/', //@locale, '.xml'))">
|
|
|
|
<xsl:value-of select="//@locale" />
|
2007-11-02 12:39:25 +00:00
|
|
|
</xsl:when>
|
2007-12-17 12:38:02 +00:00
|
|
|
<xsl:otherwise>en-us</xsl:otherwise>
|
2007-11-02 12:39:25 +00:00
|
|
|
</xsl:choose>
|
|
|
|
</xsl:variable>
|
|
|
|
|
2007-12-19 15:30:00 +00:00
|
|
|
<xsl:variable name="site_strings" select="document('../site/main.xml')//strings/string" />
|
2007-12-01 04:43:13 +00:00
|
|
|
<xsl:variable name="locale_strings" select="document(concat('../locale/', $locale, '.xml'))//strings/string" />
|
2007-10-09 15:58:37 +00:00
|
|
|
|
2007-10-28 03:06:45 +00:00
|
|
|
<!-- this kills 99% of the processed XML... sorry Tim Bray.... -->
|
2007-11-22 05:21:17 +00:00
|
|
|
<!-- had to look up Bray in Wikipedia, 2 points off my geek score -->
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:template match="@*|node()">
|
|
|
|
<xsl:if test="not(/)">
|
|
|
|
<xsl:copy>
|
|
|
|
<xsl:apply-templates select="@*|node()" />
|
|
|
|
</xsl:copy>
|
|
|
|
</xsl:if>
|
|
|
|
</xsl:template>
|
|
|
|
|
2007-10-09 15:58:37 +00:00
|
|
|
<xsl:template match="/">
|
|
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
|
|
|
|
|
|
<head>
|
2007-11-02 20:00:58 +00:00
|
|
|
<meta http-equiv="Content-Type" content="application/xhtml+xml;charset=utf-8" />
|
2007-11-30 08:35:25 +00:00
|
|
|
|
2007-12-19 15:30:00 +00:00
|
|
|
<xsl:choose>
|
|
|
|
<xsl:when test="not(//@embed='true')">
|
|
|
|
<link rel="shortcut icon" type="image/x-icon" href="/images/favicon.ico" />
|
|
|
|
<link rel="stylesheet" type="text/css">
|
|
|
|
<xsl:attribute name="href">
|
|
|
|
<xsl:value-of select="//@stylesheet" />
|
|
|
|
</xsl:attribute>
|
|
|
|
</link>
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:when test="//@embed='true'">
|
2007-12-01 04:43:13 +00:00
|
|
|
<!--
|
2007-12-19 15:30:00 +00:00
|
|
|
embedded stylesheet should rather be done through URL like
|
|
|
|
"http://localhost/video/4chan%20city/3/embed=true+stylesheet=embedded.css"
|
2007-12-01 04:43:13 +00:00
|
|
|
-->
|
2007-12-19 15:30:00 +00:00
|
|
|
<link rel="stylesheet" type="text/css">
|
|
|
|
<xsl:attribute name="href">
|
|
|
|
/style/embedded.css
|
|
|
|
</xsl:attribute>
|
|
|
|
</link>
|
|
|
|
</xsl:when>
|
|
|
|
</xsl:choose>
|
|
|
|
|
|
|
|
<xsl:if test="boolean(//results)">
|
|
|
|
|
|
|
|
<link rel="alternate" type="application/rss+xml">
|
|
|
|
<xsl:attribute name="title">
|
2007-12-27 01:54:22 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='rss_title_results_this_page']" />
|
2007-12-19 15:30:00 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_root']" />
|
|
|
|
<xsl:value-of select="$site_strings[@id='path_results']" />
|
2007-12-21 17:39:49 +00:00
|
|
|
<xsl:value-of select="//results/@query" />
|
|
|
|
&pagesize=<xsl:value-of select="//results/@pagesize" />
|
|
|
|
&page=<xsl:value-of select="//results/@page" />
|
|
|
|
&xslt=rss
|
2007-12-19 15:30:00 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
</link>
|
|
|
|
|
2007-12-27 01:54:22 +00:00
|
|
|
<link rel="alternate" type="application/rss+xml">
|
|
|
|
<xsl:attribute name="title">
|
|
|
|
<xsl:value-of select="$locale_strings[@id='rss_title_results_all_pages']" />
|
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_root']" />
|
|
|
|
<xsl:value-of select="$site_strings[@id='path_results']" />
|
2007-12-27 01:54:22 +00:00
|
|
|
<xsl:value-of select="//results/@query" />
|
|
|
|
&pagesize=99999
|
|
|
|
&page=1
|
|
|
|
&xslt=rss
|
|
|
|
</xsl:attribute>
|
|
|
|
</link>
|
|
|
|
|
2007-12-19 15:30:00 +00:00
|
|
|
</xsl:if>
|
2007-11-30 08:35:25 +00:00
|
|
|
|
2008-01-11 00:47:07 +00:00
|
|
|
<link
|
|
|
|
rel="search"
|
|
|
|
type="application/opensearchdescription+xml"
|
2008-01-12 21:45:19 +00:00
|
|
|
>
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_root']" />?xslt=opensearch
|
2008-01-12 21:45:19 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:attribute name="title">
|
|
|
|
<xsl:value-of select="$site_strings[@id='site_name']" />
|
|
|
|
</xsl:attribute>
|
|
|
|
</link>
|
2008-01-11 00:47:07 +00:00
|
|
|
|
2007-10-09 15:58:37 +00:00
|
|
|
<title>
|
|
|
|
<xsl:choose>
|
|
|
|
<xsl:when test="boolean(//frontpage)">
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='site_name']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
-
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='site_motto']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:when>
|
|
|
|
<xsl:when test="boolean(//resultspage)">
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='site_name']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
-
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='results_for_query']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
"<xsl:value-of select="//resultspage/@query" />"
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:otherwise>
|
2007-12-19 15:30:00 +00:00
|
|
|
<!--
|
|
|
|
this seems to be fail
|
|
|
|
should be fixed somehow
|
|
|
|
-->
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='site_name']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
-
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='site_motto']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:otherwise>
|
|
|
|
</xsl:choose>
|
|
|
|
</title>
|
|
|
|
</head>
|
|
|
|
|
|
|
|
<body>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:if test="not(//@embed='true')">
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<!--
|
|
|
|
<a href="/">
|
|
|
|
<img class="logo-header" src="/images/logo-small.png" alt="Yolanda logo top (160x25)" />
|
|
|
|
</a>
|
|
|
|
-->
|
|
|
|
|
|
|
|
<div class="header">
|
|
|
|
|
|
|
|
<a class="header latest-additions">
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_query_latestadditions']" />
|
2008-02-06 07:01:45 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='query_latestadditions']" />
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<a class="header most-views">
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_query_mostviews']" />
|
2008-02-06 07:01:45 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='query_mostviews']" />
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<a class="header most-downloads">
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_query_mostdownloads']" />
|
2008-02-06 07:01:45 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='query_mostdownloads']" />
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<xsl:choose>
|
|
|
|
<xsl:when test="string-length(//@username)=0">
|
|
|
|
|
|
|
|
<!--
|
|
|
|
<a class="header">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_login']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-02-06 07:01:45 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='header_login-to-upload']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
-->
|
|
|
|
<a class="header register">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_register']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='register']" />
|
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="header login">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_login']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='login']" />
|
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="header login-openid">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_login-openid']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-02-06 07:01:45 +00:00
|
|
|
<img class="openid-icon" src="/images/openid-icon.png" alt="open id logo" />
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='login_openid']" />
|
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:otherwise>
|
|
|
|
|
|
|
|
<a class="header upload-video">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_upload']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-02-06 07:01:45 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='header_upload-video']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="header preferences">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_settings']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2007-12-19 23:12:39 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='settings_details']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<!--
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='logged_in_as']" />
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="header">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
|
|
|
user/<xsl:value-of select="//@username" />
|
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="//@username" />
|
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
-->
|
|
|
|
|
|
|
|
<a class="header logout">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_logout']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:value-of select="$locale_strings[@id='logout']" />
|
|
|
|
</a>
|
2007-10-09 15:58:37 +00:00
|
|
|
|
2008-02-06 07:01:45 +00:00
|
|
|
</xsl:otherwise>
|
|
|
|
</xsl:choose>
|
|
|
|
|
|
|
|
</div>
|
2007-11-19 17:57:18 +00:00
|
|
|
|
2007-12-05 15:55:59 +00:00
|
|
|
<xsl:if test="//message">
|
|
|
|
<xsl:call-template name="message"/>
|
|
|
|
</xsl:if>
|
|
|
|
|
2007-11-19 17:57:18 +00:00
|
|
|
<xsl:if test="//search">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:call-template name="searchbar"/>
|
|
|
|
</xsl:if>
|
2007-11-19 17:57:18 +00:00
|
|
|
|
|
|
|
<xsl:if test="not(//frontpage)">
|
|
|
|
<xsl:call-template name="logo-small"/>
|
|
|
|
</xsl:if>
|
2007-10-29 15:00:40 +00:00
|
|
|
|
2007-10-28 03:06:45 +00:00
|
|
|
</xsl:if>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:choose>
|
|
|
|
<xsl:when test="//frontpage">
|
|
|
|
<xsl:call-template name="frontpage"/>
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:when test="//registerform">
|
|
|
|
<xsl:call-template name="registerform"/>
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:when test="//loginform">
|
|
|
|
<xsl:call-template name="loginform"/>
|
|
|
|
</xsl:when>
|
|
|
|
<xsl:when test="//uploadform">
|
|
|
|
<xsl:call-template name="uploadform"/>
|
|
|
|
</xsl:when>
|
2007-10-29 16:47:16 +00:00
|
|
|
<xsl:when test="//search">
|
2007-12-11 15:05:33 +00:00
|
|
|
<xsl:call-template name="results"/>
|
2007-10-28 03:06:45 +00:00
|
|
|
</xsl:when>
|
2007-12-27 14:50:08 +00:00
|
|
|
<xsl:when test="//advancedsearch">
|
|
|
|
<xsl:call-template name="advancedsearch"/>
|
|
|
|
</xsl:when>
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:when test="//video">
|
|
|
|
<xsl:call-template name="video"/>
|
|
|
|
</xsl:when>
|
2007-12-19 23:12:39 +00:00
|
|
|
<xsl:when test="//settings">
|
|
|
|
<xsl:call-template name="settings"/>
|
2007-10-29 16:47:16 +00:00
|
|
|
</xsl:when>
|
2007-10-28 03:06:45 +00:00
|
|
|
</xsl:choose>
|
2007-10-09 15:58:37 +00:00
|
|
|
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:if test="not(//@embed='true')">
|
2008-02-06 07:01:45 +00:00
|
|
|
|
2007-11-07 06:55:02 +00:00
|
|
|
<div class="footer">
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="footer view-license">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_license']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-01-05 15:11:56 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_license']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="footer view-source-code">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_source-code']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-01-05 15:11:56 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_source_code']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="footer report-bug">
|
2007-11-07 06:55:02 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_report_bug']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:attribute>
|
2008-01-05 15:11:56 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_report_bug']" />
|
2007-11-07 06:55:02 +00:00
|
|
|
</a>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<a class="footer view-xml">
|
2007-12-04 09:37:39 +00:00
|
|
|
<xsl:attribute name="href">
|
2008-01-05 15:11:56 +00:00
|
|
|
<!--
|
|
|
|
caveat: this currently does not work on root level
|
|
|
|
apache magic wanted
|
|
|
|
-->
|
|
|
|
?xslt=null
|
2007-12-04 09:37:39 +00:00
|
|
|
</xsl:attribute>
|
2008-01-05 15:11:56 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_view_xml']" />
|
2007-12-04 09:37:39 +00:00
|
|
|
</a>
|
2008-01-05 15:11:56 +00:00
|
|
|
|
2007-11-07 06:55:02 +00:00
|
|
|
</div>
|
2008-02-06 07:01:45 +00:00
|
|
|
|
|
|
|
<!--
|
|
|
|
<br />
|
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_copyright']" />
|
|
|
|
-->
|
|
|
|
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<span class="protip">
|
|
|
|
<xsl:value-of select="$locale_strings[@id='footer_warranty']" />
|
|
|
|
</span>
|
|
|
|
|
2007-11-07 06:55:02 +00:00
|
|
|
</xsl:if>
|
2007-10-09 15:58:37 +00:00
|
|
|
|
|
|
|
</body>
|
|
|
|
|
|
|
|
</html>
|
|
|
|
</xsl:template>
|
|
|
|
|
2007-11-19 17:57:18 +00:00
|
|
|
<xsl:template name="logo-small">
|
2007-10-09 15:58:37 +00:00
|
|
|
|
2008-02-06 07:01:45 +00:00
|
|
|
<!-- <a href="/">
|
2007-11-18 20:26:05 +00:00
|
|
|
<img class="logo-small" src="/images/logo-small.png" alt="Yolanda logo top (160x25)" />
|
2008-02-06 07:01:45 +00:00
|
|
|
</a>-->
|
2007-10-09 15:58:37 +00:00
|
|
|
|
2007-11-19 17:57:18 +00:00
|
|
|
</xsl:template>
|
|
|
|
|
|
|
|
<xsl:template name="searchbar">
|
|
|
|
|
2007-10-09 15:58:37 +00:00
|
|
|
<div class="search-small">
|
|
|
|
<form method="get" enctype="text/plain">
|
|
|
|
<xsl:attribute name="action">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_results']" />
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<fieldset>
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id='search']" />:
|
2007-12-16 06:06:59 +00:00
|
|
|
<input type="text" name="query" size="15">
|
2007-11-05 16:24:17 +00:00
|
|
|
<xsl:attribute name="value">
|
2007-11-26 14:25:31 +00:00
|
|
|
<xsl:if test="//results/@argument='query'">
|
|
|
|
<xsl:value-of select="//results/@value" />
|
|
|
|
</xsl:if>
|
2007-11-05 16:24:17 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
</input>
|
2007-10-09 15:58:37 +00:00
|
|
|
</fieldset>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</xsl:template>
|
|
|
|
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:template name="message">
|
2007-10-21 20:59:32 +00:00
|
|
|
|
|
|
|
<div class="messagebox">
|
2007-10-21 22:02:39 +00:00
|
|
|
<xsl:attribute name="id">
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:value-of select="/page/message/@type" />
|
2007-10-21 22:02:39 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:choose>
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:when test="/page/message/@type='error'">
|
2007-10-24 12:56:56 +00:00
|
|
|
<img src="/images/tango/dialog-error.png" />
|
2007-10-21 22:02:39 +00:00
|
|
|
</xsl:when>
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:when test="/page/message/@type='information'">
|
2007-10-24 12:56:56 +00:00
|
|
|
<img src="/images/tango/dialog-information.png" />
|
2007-10-21 22:02:39 +00:00
|
|
|
</xsl:when>
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:when test="/page/message/@type='warning'">
|
2007-10-24 12:56:56 +00:00
|
|
|
<img src="/images/tango/dialog-warning.png" />
|
2007-10-21 22:02:39 +00:00
|
|
|
</xsl:when>
|
|
|
|
</xsl:choose>
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:variable name="messagetext" select="/page/message/@text" />
|
2007-10-26 12:51:00 +00:00
|
|
|
<xsl:value-of select="$locale_strings[@id=$messagetext]" />
|
2007-12-29 04:51:14 +00:00
|
|
|
<xsl:value-of select="/page/message/@value" />
|
2007-10-21 22:02:39 +00:00
|
|
|
<!-- probably one can do this on one line, dunno how -->
|
2007-10-21 20:59:32 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
</xsl:template>
|
|
|
|
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:template name="tagcloud">
|
2007-11-02 12:12:44 +00:00
|
|
|
<xsl:variable name="max" select="//tagcloud/tag/count[not(//tagcloud/tag/count > .)]" />
|
|
|
|
<xsl:variable name="min" select="//tagcloud/tag/count[not(//tagcloud/tag/count < .)]" />
|
2007-10-09 15:58:37 +00:00
|
|
|
<div class="tagcloud">
|
2007-10-28 03:06:45 +00:00
|
|
|
<xsl:for-each select="//tagcloud/tag">
|
2007-10-09 15:58:37 +00:00
|
|
|
<xsl:sort select="text" order="ascending" data-type="text" />
|
|
|
|
<a class="tag">
|
|
|
|
<xsl:attribute name="style">
|
2007-11-22 05:21:17 +00:00
|
|
|
<!--
|
2007-11-22 10:15:32 +00:00
|
|
|
scale *should* be logarihmic, but that's not widely supportet
|
2007-11-22 05:21:17 +00:00
|
|
|
-->
|
2007-11-02 12:12:44 +00:00
|
|
|
font-size:<xsl:value-of select="round((32-12)*(number(count)-number($min))div (number($max)-number($min)))+12" />px
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:attribute>
|
|
|
|
<xsl:attribute name="href">
|
2008-02-14 15:23:28 +00:00
|
|
|
<xsl:value-of select="$site_strings[@id='path_results']" />
|
2007-10-12 12:42:01 +00:00
|
|
|
tag:
|
|
|
|
<xsl:value-of select="text" />
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:attribute>
|
2007-11-22 10:15:32 +00:00
|
|
|
|
2007-10-09 15:58:37 +00:00
|
|
|
<xsl:value-of select="text" />
|
2007-11-22 05:21:17 +00:00
|
|
|
<!--
|
|
|
|
unnecessary, except for debug purposes
|
2007-10-09 15:58:37 +00:00
|
|
|
(<xsl:value-of select="count" />)
|
2007-11-22 05:21:17 +00:00
|
|
|
-->
|
2007-10-09 15:58:37 +00:00
|
|
|
</a>
|
2007-11-22 10:15:32 +00:00
|
|
|
‌
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:for-each>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</xsl:template>
|
|
|
|
|
2007-10-29 16:47:16 +00:00
|
|
|
|
2007-10-09 15:58:37 +00:00
|
|
|
</xsl:stylesheet>
|