Hi,
May be I should have included my files..
Why do i get the following error while the examples run fine...
Source XML Error: Value must be quoted.
I have tried putting quotes in the xml file, but nothing seems to work.
Pls Help,
Thanks in advance..
Ishpal
----------------------------------------------------------------------
1) XML file is.......
<?xml version="1.0"?>
<!DOCTYPE doc SYSTEM "http://www.testdomain.cmx/hello/xsl/XML1.dtd">
<?xml-stylesheet href="http://www.testdomain.cmx/hello/xsl/XML1.xsl"
type="text/xsl"?>
<top>
<record>
<key>
<id>1</id>
</key>
<info>
<name>ish1cview</name>
<age>1</age>
</info>
<contact-info>
<address>g21/3 rajouri garden</address>
<phone>phone1</phone>
<email>[EMAIL PROTECTED]</email>
</contact-info>
</record>
</top>
2) DTD file is.....
<!ELEMENT top (record)>
<!ELEMENT record (key, info, contact-info)>
<!ELEMENT key (id)>
<!ELEMENT info (name, age)>
<!ELEMENT contact-info (address,phone,email)>
<!ELEMENT id (#PCDATA)*>
<!ELEMENT name (#PCDATA)*>
<!ELEMENT age (#PCDATA)*>
<!ELEMENT phone (#PCDATA)*>
<!ELEMENT email (#PCDATA)*>
<!ELEMENT address (#PCDATA)*>
3) XSL file is .....
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
vrsion="1.0">
<xsl:strip-space elements="top record key info contact-info"/>
<xsl:output method="xml" int="yes"/>
<xsl:output media-type="text/html" />
<xsl:template match="top">
<html>
<head>
<TITLE><xsl:value-of select="title"/></TITLE>
</head>
<body bgcolor="white"><center>
<xsl:apply-templates/>
<hr/>
</center>
</body>
</html>
</xsl:template>
<xsl:template match="record">
<hr/>
<table cellspacing=5 cellpadding=4>
<xsl:apply-templates/>
</table>
</xsl:template>
<xsl:template match="key">
<tr>
<xsl:apply-templates/>
</tr>
</xsl:template>
<xsl:template match="info">
<tr>
<xsl:apply-templates/>
</tr>
</xsl:template>
<xsl:template match="contact-info">
<tr><td colspan=4>
<xsl:apply-templates/>
</td></tr>
</xsl:template>
<xsl:template match="id">
<td bgcolor=c0c0c0>UserId</td><td colspan=3>
<xsl:apply-templates/>
</td>
</xsl:template>
<xsl:template match="name">
<td bgcolor=c0c0c0>User Name</td><td>
<xsl:apply-templates/>
</td>
</xsl:template>
<xsl:template match="age">
<td bgcolor=c0c0c0>Age</td><td>
<xsl:apply-templates/>
</td>
</xsl:template>
<xsl:template match="address">
<tr><td bgcolor=c0c0c0>Address</td><td colspan=3>
<xsl:apply-templates/>
</td></tr>
</xsl:template>
<xsl:template match="phone">
<tr><td bgcolor=c0c0c0>Phone</td><td colspan=3>
<xsl:apply-templates/>
</td></tr>
</xsl:template>
<xsl:template match="email">
<tr><td bgcolor=c0c0c0>E-mail</td><td>
<xsl:apply-templates/>
</td></tr>
</xsl:template>
</xsl:stylesheet>