xsl & xsd: support @id for block-level elements
example link with anchor: http://datenspuren.de/2015/cfp.html#einreichung
This commit is contained in:
parent
1960655474
commit
f944f9d229
|
@ -45,7 +45,7 @@ Der Chaos Computer Club Dresden lädt daher dazu ein, Vorschläge für technisch
|
|||
<dd>16. August 2015</dd>
|
||||
<dt>Format</dt>
|
||||
<dd>Kurzfassung (max. 300 Wörter) für Vortrag, Workshop, Installation/Performance, Junghackertrack</dd>
|
||||
<dt>Einreichung</dt>
|
||||
<dt id="einreichung">Einreichung</dt>
|
||||
<dd>
|
||||
Vorträge und Workshops über das Konferenzsystem "frab":
|
||||
<link href="https://frab.cccv.de/en/DS2015/cfp/session/new#new_user">https://frab.cccv.de/en/DS2015/cfp/session/new</link>
|
||||
|
|
|
@ -111,6 +111,7 @@
|
|||
<xs:group ref="Inline.class" minOccurs="0"
|
||||
maxOccurs="unbounded"/>
|
||||
</xs:sequence>
|
||||
<xs:attribute name="id" type="xs:string" use="optional"/>
|
||||
</xs:complexType>
|
||||
|
||||
<xs:group name="Inline.class">
|
||||
|
|
|
@ -9,44 +9,51 @@
|
|||
exclude-result-prefixes="xsl rss rdf date str">
|
||||
|
||||
<xsl:template match="pre">
|
||||
<pre><xsl:apply-templates/></pre>
|
||||
<pre><xsl:call-template name="copy-id"/><xsl:apply-templates/></pre>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="p">
|
||||
<xsl:if test="@title">
|
||||
<h3>
|
||||
<xsl:call-template name="copy-id"/>
|
||||
<xsl:value-of select="@title"/>
|
||||
</h3>
|
||||
</xsl:if>
|
||||
|
||||
<p class="{@class}">
|
||||
<xsl:if test="not(@title)">
|
||||
<xsl:call-template name="copy-id"/>
|
||||
</xsl:if>
|
||||
|
||||
<xsl:apply-templates/>
|
||||
</p>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="dl">
|
||||
<dl class="{@class}">
|
||||
<xsl:call-template name="copy-id"/>
|
||||
<xsl:apply-templates/>
|
||||
</dl>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="dh">
|
||||
<dt class="main"><xsl:apply-templates/></dt>
|
||||
<dt class="main"><xsl:call-template name="copy-id"/><xsl:apply-templates/></dt>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="dt">
|
||||
<dt><xsl:apply-templates/></dt>
|
||||
<dt><xsl:call-template name="copy-id"/><xsl:apply-templates/></dt>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="dd">
|
||||
<dd><xsl:apply-templates/></dd>
|
||||
<dd><xsl:call-template name="copy-id"/><xsl:apply-templates/></dd>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="ul">
|
||||
<ul><xsl:apply-templates/></ul>
|
||||
<ul><xsl:call-template name="copy-id"/><xsl:apply-templates/></ul>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="ol">
|
||||
<ol><xsl:apply-templates/></ol>
|
||||
<ol><xsl:call-template name="copy-id"/><xsl:apply-templates/></ol>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="li">
|
||||
|
@ -54,7 +61,7 @@
|
|||
</xsl:template>
|
||||
|
||||
<xsl:template match="blockquote">
|
||||
<blockquote><xsl:apply-templates/></blockquote>
|
||||
<blockquote><xsl:call-template name="copy-id"/><xsl:apply-templates/></blockquote>
|
||||
</xsl:template>
|
||||
|
||||
<!-- Bilder in News-Einträgen haben Pfad immer relativ zu /images/news/ -->
|
||||
|
@ -509,6 +516,12 @@
|
|||
|
||||
<!-- Helpers -->
|
||||
|
||||
<xsl:template name="copy-id">
|
||||
<xsl:if test="@id">
|
||||
<xsl:attribute name="id"><xsl:value-of select="@id"/></xsl:attribute>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template name="format-filesize">
|
||||
<xsl:param name="value"/>
|
||||
|
||||
|
|
Loading…
Reference in New Issue