XSL / MOZILLA : Pourquoi ce qui est simple ne l'est il pas ? help !

XSL / MOZILLA : Pourquoi ce qui est simple ne l'est il pas ? help ! - XML/XSL - Programmation

Marsh Posté le 26-08-2003 à 15:31:09    

Bonjour à tous,
 
J'ai un problème d'espace vertical sous Mozilla qui apparait systématiquement sous les images lorsque je suis dans un fichier XSL...
Pourtant le fichier html identique lui se comporte correctement tout reste collé pile-poile.
 
mon fichier html de test :
 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 
<html>
<body leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0" marginwidth="0" marginheight="0">
<img src="http://img.up-d8.com/x/x/04.gif" width="48" height="61" hspace="0" vspace="0" border="0" /><br />
<table width="50" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
 <td bgcolor="#800080"><spacer type="block" width="50" height="50"/></td>
</tr>
</table>
<table width="50" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
 <td>Pouet</td>
</tr>
</table>
</body>
</html>
 
tout est OK sous mozilla et IE l'image est bien collé au tableau coloré juste en dessous.
 
mais une fois intégré dans un fichier XSL, un espace vertical apparait sous mozilla ! grrr...
 
mes fichiers de test :
 
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="zarb.xsl"?>
<page>
 <text>Pouet</text>
</page>
 
 
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">  
<xsl:output method="html"/>
<xsl:template match="/">
 
<html>
<body leftmargin="0" topmargin="0" rightmargin="0" bottommargin="0" marginwidth="0" marginheight="0">
<img src="http://img.up-d8.com/x/x/04.gif" width="48" height="61" hspace="0" vspace="0" border="0" /><br />
<table width="50" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
 <td bgcolor="#800080"><spacer type="block" width="50" height="50"/></td>
</tr>
</table>
<table width="50" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
 <td><xsl:value-of select="page/text"/></td>
</tr>
</table>
</body>
</html>
 
</xsl:template>
</xsl:stylesheet>
 
 
Où est mon erreur ? Qu'est-ce que le Mozilla y veu de plus ????
 
 
 
 
 

Reply

Marsh Posté le 26-08-2003 à 15:31:09   

Reply

Marsh Posté le 26-08-2003 à 17:03:54    

:ouch: Vu la gueule de ton code HTML, ça m'étonne pas qu'il bug !


---------------
W3C : Leading the Web to Its Full Potential... - Membre du W3C l33t club
Reply

Marsh Posté le 31-08-2003 à 17:48:17    

Mise à part les tags invalides qui datent des problèmes de compatibilité entre NS4 et IE4, le code HTML ne me choque pas en soit...
 
Par contre, pour obtenir un rendu rigoureusement identique entre avec les différent navigateurs, utilise des styles CSS plutôt que des attributs.
 
Et oublie le code compatible NS4, de toute façon il ne supporte pas le XSL


Message édité par MagicBuzz le 31-08-2003 à 17:49:12
Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed