This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
org.apache.xalan.xslt.XSLProcessorException: ???
- To: "'xsl-list at lists dot mulberrytech dot com'" <xsl-list at lists dot mulberrytech dot com>
- Subject: [xsl] org.apache.xalan.xslt.XSLProcessorException: ???
- From: manisha <mmalviya at optechsolutions dot com>
- Date: Wed, 24 Jan 2001 06:44:29 +0530
- Reply-To: xsl-list at lists dot mulberrytech dot com
Hello All,
I am facing the following problem while tranforming a valid xml to html
through the following xsl.What is the reason if some one can help me.
=========
Exception is as followes:
==========
The root element is required in a well-formed document. at org.apache.xalan.xslt.XSLTEngineImpl.error(XSLTEngineImpl.java:1630)
*****************************************************************************************
XSL USED:
-----------------------------------------------------------------------------------------
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" >
<xsl:output method="html"/>
<xsl:template match="/">
<html>
<head>
<title>Department</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-88591"></meta>
<link rel="stylesheet" href="../../Content_Files/Form.css"></link>
</head>
<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" tracingsrc="Layout6.jpg" tracingopacity="40" >
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="1">
<tr height="1" >
<td><img src="images/Spacer_T.gif" width="1" height="1"></img></td>
</tr>
</table>
<table width="760" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="20" width="780">
<div align="right"></div>
</td>
</tr>
</table>
<table width="90%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="3"><img src="images/Spacer_5px.gif" width="5" height="5"></img></td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr align="center">
<td colspan="2" height="21"><span class="Heading"><font face="Verdana, Arial, Helvetica, sans-serif" size="1"><b><font color="#FF0000" size="2" class="Heading"><u><font color="#990033">EXISTING
DEPARTMENTS </font></u></font></b></font></span></td>
</tr>
<tr>
<td colspan="2" height="7">
<hr color="#990000" size="1"></hr>
</td>
</tr>
</table>
<table width="760" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td width="1" height="65"></td>
<td colspan="4" class="TableBG2" height="65">
<table width="100%" border="1" cellspacing="0" cellpadding="0" class="Bgtext" bordercolor="#980038" bordercolorlight="#FFF4E8">
<tr align="center">
<td width="23%" class="TableBG1"><b>Sr. No.</b></td>
<td width="77%" class="TableBG1"><b>DEPARTMENT</b></td>
</tr>
<xsl:for-each select="rowset/row">
<tr align="center">
<td width="23%" class="TableBG1">
<xsl:number count="*"/>
<xsl:text>. </xsl:text></td>
<td width="77%" class="TableBG1">
<xsl:value-of select="DEPARTMENT/@value"/></td>
</tr>
</xsl:for-each >
</table>
</td>
<td width="2" height="65"></td>
</tr>
</table>
<br></br>
<hr color="#990000" size="1" width="100%" align="left"></hr>
<p></p>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
-----------------------------------------------------
XML USED IS:
---------------------------------------------------
<?xml version="1.0"?>
<!DOCTYPE rowset [
<!ELEMENT rowset (row)*>
<!ELEMENT row (DEPARTMENT)>
<!ELEMENT DEPARTMENT EMPTY>
<!ATTLIST DEPARTMENT
value CDATA #IMPLIED
type CDATA #FIXED "12">
]>
<rowset>
<row>
<DEPARTMENT value="Software Maintenance"/>
</row>
<row>
<DEPARTMENT value="Customer Support"/>
</row>
<row>
<DEPARTMENT value="Testing"/>
</row>
<row>
<DEPARTMENT value="Quality Control"/>
</row>
<row>
<DEPARTMENT value="Software Development"/>
</row>
<row>
<DEPARTMENT value="Market Management"/>
</row>
<row>
<DEPARTMENT value="Sales"/>
</row>
<row>
<DEPARTMENT value="Shipping"/>
</row>
<row>
<DEPARTMENT value="Packaging"/>
</row>
<row>
<DEPARTMENT value="Human Resources Department"/>
</row>
<row>
<DEPARTMENT value="System"/>
</row>
<row>
<DEPARTMENT value="Planning"/>
</row>
<row>
<DEPARTMENT value="Administration"/>
</row>
<row>
<DEPARTMENT value="Marketing"/>
</row>
<row>
<DEPARTMENT value="Accounts"/>
</row>
</rowset>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list