[xslt] Re: Problem with external documents and encoding
- From: Christopher Morrison <cm0rris0n yahoo com>
- To: "'xml gnome org'" <xml gnome org>,"'xslt gnome org'" <xslt gnome org>
- Subject: [xslt] Re: Problem with external documents and encoding
- Date: Wed, 15 May 2002 17:13:04 -0700 (PDT)
Please disregard ... I can get this working using
xsltproc , so the problem must be in the wrappers
(ns_xml module for AOLserver) I am using to access
libxml/libxslt. Sorry to bother you.
--- Chris Morrison <CMorrison@foxsports.com> wrote:
> Trying to apply XSL file FOO.XSL to XML file BAR.XML
> with external document
> BAZ.XML using libxml2-2.4.21 and libxslt-1.0.17
> returns an error:
> I'm quite confused because the encoding seems to be
> clearly declared in
> BAZ.XML.
>
> ------------------
> Error :
> Entity: line 1: error: xmlSwitchToEncoding : no
> input
> <?xml version="1.0" encoding="ISO-8859-1"?>
> ^
> Entity: line 35: error: Input is not proper UTF-8,
> indicate encoding !
> <name first-name="José"/>
> ^
> Entity: line 35: error: Bytes: 0xE9 0x22 0x20 0x6C
>
> ------------------
> FOO.XSL
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <xsl:stylesheet id="test" version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> <xsl:output method="xml" indent="no"
> omit-xml-declaration="yes" />
> <xsl:variable name="externalXML"
>
select="document('http://localhost/BAZ.XML')/topnode"/>
> <xsl:output select="$externalXML/name/@first-name"/>
> </xsl:stylesheet>
>
> ------------------
>
> ------------------
> BAR.XSL
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <topnode>
> <doesnotmatter>
> </topnode>
>
> ------------------
> With BAZ.XML looking like :
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <topnode>
> <name first-name="José"/>
> </topnode>
>
> ------------------
>
> The only thing closely resembling this in the
> listserv archives is quite old
> and the response says its fixed:
>
http://mail.gnome.org/archives/xml/2001-April/msg00075.html
>
> From what I can tell, I'm using the most recent
> versions of everything and
> there are no relevant open bugs listed:
> http://bugzilla.gnome.org/buglist.cgi?product=libxml
> or
>
http://bugzilla.gnome.org/buglist.cgi?product=libxslt
>
>
>
>
>
__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]