This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Another newbie question
I am banging my head against the wall working on My Very First XML Page (TM) and
was hoping someone here could help me, as I'm fairly sure it's the XSL I bollixed
up.
The XSL is as follows:
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="document">
<xsl:apply-templates/>
</xsl:template>
<body bgcolor="Black" text="White" link="#CCCCCC" vlink="Red" alink="Blue"/>
<xsl:template match="title">
<font face="arial,helvetica,helv" size="+3"><b><xsl:apply-templates
select="name"/>
<xsl:apply-templates select="num"/></b></font>
</xsl:template>
<xsl:template match="body">
<table width="600" border="0" cellpadding="6">
<tr>
<td align="top" valign="left">
<xsl:apply-templates match="img"/>
</td>
<td align="top" valign="left">
<p><font color="#000000"><xsl:apply-templates match="text"/></font></p>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>
...and the XML is:
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="gallery.xsl"?>
<!DOCTYPE document SYSTEM "gallery.dtd">
<document>
<title name="John" num="3"/>
<body>
<img src="john3.jpg" alt="Lighting Candles" height="257" width="287"/>
<text>Lighting candles.</text>
</body>
<footer>
<index href="index.htm"/>
<yplt href="../pretty.htm"/>
<home href="../index.html"/>
<copyright/>
</footer>
</document>
I am trying to emulate:
http://www.obscure.org/~rednikki/john/john3.htm
but so far all I get is the black background.
Obviously, I've screwed up. If anyone can take the time to point me in the right
direction, I'd be much obliged.
- Nikki
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list