JustinEzequiel
Programmer
The following works just fine in IE but not in FireFox.
What am I doing wrong?
The FireFox page-loading indicator just keeps going but the page does not load completely.
If I add a document.close(), the indicator stops but I do not get the rest of the output.
FireFox output stops at the emphasized "This will work".
What am I doing wrong?
The FireFox page-loading indicator just keeps going but the page does not load completely.
If I add a document.close(), the indicator stops but I do not get the rest of the output.
FireFox output stops at the emphasized "This will work".
Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="[URL unfurl="true"]http://www.w3.org/1999/XSL/Transform">[/URL]
<xsl:output method='html' version='1.0' encoding='UTF-8'/>
<xsl:variable name="root" select="/files/@path"/>
<xsl:template match="/">
<html>
<head>
<title>Directory listing for <xsl:value-of select="$root" /></title>
</head>
<body>
<script type="text/javascript">
document.write ("<em>This will work<\/em>")
</script>
<hr />
<xsl:apply-templates select="files"/>
<hr />
</body>
</html>
</xsl:template>
<xsl:template match="files">
<table border="1" cellspacing="3" cellpadding="3" style="border-collapse:collapse">
<tr>
<th>Name</th>
<th>Size</th>
<th>Modified</th>
</tr>
<xsl:for-each select="file">
<xsl:sort select="@name"/>
<tr>
<td><xsl:value-of select="@name" /></td>
<td align="right"><xsl:value-of select="format-number(@size, '#,###')" /></td>
<td><xsl:value-of select="@date" /></td>
</tr>
</xsl:for-each>
</table>
</xsl:template>
</xsl:stylesheet>
Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="ONLINE.xsl"?>
<files path="/springer/mik60007/trunk/graphics/output/ONLINE/">
<file date="2007-02-12 13:57:16" name="s14344-006-0007-4flb1.gif" size="1748517485" />
<file date="2007-02-12 13:57:16" name="s14344-006-0007-4flb2.gif" size="15407" />
<file date="2007-02-12 13:57:16" name="s14344-006-0007-4flb3.gif" size="15366" />
</files>