1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
|
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp " ">
<!ENTITY copy "©">
<!ENTITY reg "®">
<!ENTITY trade "">
<!ENTITY mdash "">
<!ENTITY ldquo "">
<!ENTITY rdquo "">
<!ENTITY pound "£">
<!ENTITY yen "¥">
<!ENTITY euro "">
]>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="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="liens">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<link rel="stylesheet" type="text/css" href="liens.css" />
<title>Liens</title>
</head>
<body>
<table align="center">
<tr valign="top">
<xsl:apply-templates select="categorie" />
</tr>
</table>
<xsl:apply-templates select="test" />
</body>
</html>
</xsl:template>
<!-- Affichage des catégories -->
<xsl:template match="categorie">
<td>
<table border="0" cellpadding="0" cellspacing="3" class="liens">
<xsl:attribute name="width"><xsl:value-of select="/liens/tableaux/@largeur" /></xsl:attribute>
<tr align="center"><td class="categorie"><xsl:value-of select="@titre" /></td></tr>
<tr align="center"><td><hr width="85%" /></td></tr>
<xsl:apply-templates select="lien" />
</table>
</td>
<xsl:if test="position() mod 3 = 0">
</tr><tr> <!-- LE PROBLEME EST ICI -->
</xsl:if>
</xsl:template>
<!-- Affichage des catégories -->
<xsl:template match="lien">
<tr align="center">
<td onmouseover="this.className='tdDessus'" onmouseout="this.className='tdHors'">
<a target="_blank">
<xsl:attribute name="href"><xsl:value-of select="@url" /></xsl:attribute>
<xsl:value-of select="@titre" />
</a>
</td>
</tr>
</xsl:template>
</xsl:stylesheet> |
Partager