I am having problems parsing xml files through apache/mod-xslt. From
the command line I get this output from a simple test:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Hello World</title>
</head>
<body><h1>Hello World</h1></body>
</html>
<!-- -* Generated by mod-xslt 1.3.5; http://www.mod-xslt2.com/
-* Copyright (C) 2002,2003 Carlo Contavalli - <ccontavalli at
masobit.net>
-* derived from work by Philipp Dunkel and others
(http://www.mod-xslt2.com/main/credits.xml)
-* Thanks to http://www.masobit.net/ for paying me while working on
mod-xslt
-* and for providing resources to the project. -->
But when I view the same file through a web browser I get a 500. Here
is the output from the error log files:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
/var/www/html/xml/winetest.xml:5:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt: error:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
Opening and ending tag mismatch: meta line 3 and head
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
</head>
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
^
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
/var/www/html/xml/winetest.xml:7:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt: error:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
Opening and ending tag mismatch: head line 2 and html
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
</html>
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
^
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
/var/www/html/xml/winetest.xml:14:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt: error:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
Premature end of data in tag html line 1
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt:
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt: ^
[Thu Aug 12 15:18:10 2004] [error] [client 129.99.134.] mod_xslt: fatal
- failed loading file: /var/www/html/xml/winetest.xml
It seems that the meta tag is giving the parser problems because it
does not have an end tag. Is there a option I can give mod_xslt so this
can stop?
System: RHAS3
Apache: 2.0.46
Any ideas or suggestions would be appreciated.
Thank you,
Ryan
xml document:
<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
<?xml-stylesheet type="text/xsl" method="http" href="./winetest.xsl"
media="all" alternate="no" title="For any web browser"
charset="ISO-8859-1"?>
<greetings>
<greeting>Hello World</greeting>
</greetings>