summaryrefslogtreecommitdiff
path: root/gentoobrowse/xslt/base.xslt
diff options
context:
space:
mode:
authorrandomdan <randomdan@localhost>2011-02-22 15:53:58 +0000
committerrandomdan <randomdan@localhost>2011-02-22 15:53:58 +0000
commit32ab47ed36595eb7af39e8d57c176022c0195cbc (patch)
tree66006d4a6c876bf1e40a1e645eab54da9b61cb13 /gentoobrowse/xslt/base.xslt
parentRename rowsets so they are unique (diff)
downloadgentoobrowse-32ab47ed36595eb7af39e8d57c176022c0195cbc.tar.bz2
gentoobrowse-32ab47ed36595eb7af39e8d57c176022c0195cbc.tar.xz
gentoobrowse-32ab47ed36595eb7af39e8d57c176022c0195cbc.zip
Move stuff round to tidy it up and add HTTP permissions to deny access to P2 config files
Diffstat (limited to 'gentoobrowse/xslt/base.xslt')
-rw-r--r--gentoobrowse/xslt/base.xslt81
1 files changed, 81 insertions, 0 deletions
diff --git a/gentoobrowse/xslt/base.xslt b/gentoobrowse/xslt/base.xslt
new file mode 100644
index 0000000..eecc5de
--- /dev/null
+++ b/gentoobrowse/xslt/base.xslt
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:project2="http://project2.randomdan.homeip.net" exclude-result-prefixes="project2" >
+ <xsl:output encoding="utf-8" method="xml" media-type="text/html" indent="yes"
+ doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
+ doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN" />
+ <xsl:template match="/gentoo">
+ <html>
+ <head>
+ <link rel="stylesheet" href="/css/screen.css" type="text/css" />
+ <link rel="shortcut icon" href="/images/glogo-small.png" type="image/png" />
+ <link rel="start" href="/" />
+ <link rel="search" href="/search" />
+ <meta http-equiv="content-language" content="en" />
+ <xsl:call-template name="head" />
+ <script type="text/javascript">
+ var _gaq = _gaq || [];
+ _gaq.push(['_setAccount', 'UA-19177673-1']);
+ _gaq.push(['_trackPageview']);
+
+ (function() {
+ var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+ ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
+ })();
+ </script>
+ </head>
+ <body>
+ <h1>Gentoo Browse</h1>
+ <div class="tabs">
+ <a href="/">Home</a> |
+ <a href="/categories">Browse</a> |
+ <a href="/popular">Popular</a> |
+ <a href="/search" rel="nofollow">Search</a> |
+ <xsl:if test="count(/gentoo/project2:session/project2:var[@name='loggedInUserID']) = 0">
+ <a href="/login" rel="nofollow">Login</a>
+ </xsl:if>
+ <xsl:if test="count(/gentoo/project2:session/project2:var[@name='loggedInUserID']) &gt; 0">
+ <a href="/accountHome" rel="nofollow">My Account</a>
+ </xsl:if>
+ </div>
+ <table width="100%">
+ <tr>
+ <td class="colLeft">
+ <h2>News</h2>
+ </td>
+ <td class="content">
+ <xsl:call-template name="content" />
+ </td>
+ </tr>
+ </table>
+ <div class="trademark">
+ This website is not an official Gentoo website.
+ The name "Gentoo" and the "g" logo are trademarks of the Gentoo Foundation, Inc.
+ </div>
+ <div class="poweredby">
+ Powered by |
+ <xsl:for-each select="/gentoo/power/by">
+ <a>
+ <xsl:attribute name="href"><xsl:value-of select="url" /></xsl:attribute>
+ <xsl:value-of select="name" />
+ </a> |
+ </xsl:for-each>
+ Many thanks.
+ </div>
+ </body>
+ </html>
+ </xsl:template>
+ <xsl:template name="head">
+ <title>Gentoo Browse</title>
+ </xsl:template>
+ <xsl:template match="package">
+ <li>
+ <a>
+ <xsl:attribute name="href">/package/<xsl:value-of select="catname" />/<xsl:value-of select="pkgname" /></xsl:attribute>
+ <xsl:attribute name="title"><xsl:value-of select="description" /></xsl:attribute>
+ <xsl:value-of select="catname" />/<xsl:value-of select="pkgname" />
+ </a> - <xsl:value-of select="description" />
+ </li>
+ </xsl:template>
+</xsl:stylesheet>