Re: [xsl] Encoding/Entities problems

Subject: Re: [xsl] Encoding/Entities problems
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Mon, 28 Oct 2002 17:24:55 -0500

You can avoid retyping and use the entities you are used to (& c c e d i l ; for ç etc.) if you provide your stylesheet with a DOCTYPE declaration that calls in the necessary entity declarations.

If you consult an XML manual on DTD internal subsets and in particular on invoking external declarations, you should be able to stitch together what you need. There's also plenty of help on line if you know what to look for (the usual problem): you could start at

Once you have downloaded the files containing the declarations, your solution will eventually look something like this:

<!DOCTYPE xsl:stylesheet [
<!ENTITY % ISOlat1 PUBLIC "ISO 8879-1986//ENTITIES Added Latin 1//EN//XML"
                          "ISOlat1.pen" >
<xsl:stylesheet version="1.0"

...assuming one of the entity sets you need is available as ISOlat1.pen.

These declarations allow the parser to know that the ccedil entity is a representation for the "ç" character. This information is *not* hard-wired into the parser.

I hope that helps,

This is really an XML parsing problem, not an XSLT problem.
At 02:48 PM 10/28/2002, you wrote:
Hi all,

I´m having a problem with encoding.
in my xml and xsl files, i´m using encoding="ISO-8859-1"

my xsl, xml editor (xml spy) says that the document is well-formated
but i´m having this error in the browser:

msxml4.dll error '80004005'

The stylesheet does not contain a document element. The stylesheet may be
empty, or it may not be a well-formed XML document.

my text are in portuguese (i´m from brazil), I use: ç, á, é, í, ó, ú, ã,
ô, etc...
in the document I put "&ccedil";  but if I change it to "ç" it works well..
the browse accepts it.

but i´m typing the text in dreamweaver mx. and it converts automaticly the ç
to &ccedil, the à to &aacute, etc..

sooooooo..there´s in any solution for it? I really don´t want to type all again without the entities.

thanks a lot

Paulo Fabiano Langer

XSL-List info and archive:

Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.      
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
  Mulberry Technologies: A Consultancy Specializing in SGML and XML

XSL-List info and archive:

Current Thread