Skip to content

Commit

Permalink
Optimised transform (how it should be in xdv 0.4)
Browse files Browse the repository at this point in the history
  • Loading branch information
Laurence Rowe authored and garbas committed May 29, 2010
1 parent c074157 commit 43c32db
Showing 1 changed file with 53 additions and 0 deletions.
53 changes: 53 additions & 0 deletions optimised.xsl
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:dv="http://namespaces.plone.org/xdv" xmlns:esi="http://www.edge-delivery.org/esi/1.0" xmlns:exsl="http://exslt.org/common" xmlns:str="http://exslt.org/strings" xmlns:xhtml="http://www.w3.org/1999/xhtml" version="1.0" exclude-result-prefixes="exsl str dv xhtml esi">
<xsl:output method="xml" indent="no" omit-xml-declaration="yes" media-type="text/html" encoding="utf-8" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>

<xsl:template match="/">
<html><head><xsl:apply-templates select="/html/head/base"/><meta http-equiv="content-type" content="text/html; charset=utf-8"/><xsl:apply-templates select="/html/head/title"/><meta name="keywords" content=""/><meta name="description" content=""/><link href="http://oskar:8080/theme/style.css" rel="stylesheet" type="text/css" media="screen"/></head><body>&#13;
<div id="header">&#13;
<div id="menu"><xsl:apply-templates select="//*[@id = 'portal-globalnav']"/></div>&#13;
<xsl:comment> end #menu </xsl:comment>&#13;
<div id="search"><xsl:apply-templates select="//*[@id = 'portal-searchbox']"/></div>&#13;
<xsl:comment> end #search </xsl:comment>&#13;
</div>&#13;
<xsl:comment> end #header </xsl:comment>&#13;
<xsl:comment> end #header-wrapper </xsl:comment>&#13;
<div id="logo">&#13;
<h1><a href="#">Substantial </a></h1>&#13;
<p><em> template design by <a href="http://www.freecsstemplates.org/"> CSS Templates</a></em></p>&#13;
</div>&#13;
<hr/><xsl:comment> end #logo </xsl:comment><div id="page">&#13;
<div id="content">&#13;
<div id="content-bgtop">&#13;
<div id="content-bgbtm"><xsl:apply-templates select="//*[@id = 'content']/*"/></div>&#13;
</div>&#13;
</div>&#13;
<xsl:comment> end #content </xsl:comment>&#13;
<div id="sidebar"><xsl:apply-templates select="//*[@id = 'portal-column-two']"/></div>&#13;
<xsl:comment> end #sidebar </xsl:comment>&#13;
<div style="clear: both;"> </div>&#13;
<xsl:comment> end #page </xsl:comment>&#13;
<div id="footer">&#13;
<p><xsl:apply-templates select="//*[@id = 'portal-colophon']/div[contains(concat(' ', normalize-space(@class), ' '), ' colophonWrapper ')]/ul/li"/></p>&#13;
</div>&#13;
<xsl:comment> end #footer </xsl:comment>&#13;
</div>&#13;
<xsl:apply-templates select="/html/body/@id"/></body></html>
</xsl:template>
<xsl:template match="style|script|xhtml:style|xhtml:script" priority="5">
<xsl:element name="{local-name()}">
<xsl:apply-templates select="@*"/>
<xsl:value-of select="text()" disable-output-escaping="yes"/>
</xsl:element>
</xsl:template>
<xsl:template match="node()|@*" priority="1">
<xsl:copy>
<xsl:apply-templates select="node()|@*"/>
</xsl:copy>
</xsl:template>

<!--
Extra templates
-->

</xsl:stylesheet>

0 comments on commit 43c32db

Please sign in to comment.