Dear Sirs / Madams,

I am currently using xalan 1.2.2. and I have problems with the writing of html meta tags. The html output is without a closing tag. Even though the closing tag (either /> or </meta>) is specified in the XSL file, however it was eliminated.

The following is the XSL file:

<?xml version='1.0' encoding='utf-8' ?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:output method="html" doctype-system="xhtml1-transitional.dtd"/>

<xsl:template match="Parent">

<html lang="en-sg">

<head><title></title>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>

</head>

</xsl:template>

the html output is:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

Note: There is no closing tag

even when I put

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>

in the XSL, however the output is still the same as the above.

My html file needs to be compliant to xhtml DTD. Therefore, I would need the meta tags to have a closing tag as well.

In summary, I need to clarify 2 things:

1. Is this a known problem in Xalan 1.2.2? If it is, is there a work around? most preferably using the same Xalan version.

I have tried to construct the tags using <xsl:text>&lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8"/&gt;</xsl:text>

However, they are not treated as html tag, therefore instead of being treated as html tag, it is treated as a normal text.

2. I have specified the closing tag in my XSL file, however in the html output, it is eliminated.

Is there a flag or something like that in the configuration that I can set, so that the closing tag is not eliminated automatically.

3. Is there a way in Xalan 1.2.2 that conformance to XHTML is checked?

I really look forward to your reply and I thank you for your time.

With Regards,

Susan



MSN Photos is the easiest way to share and print your photos: Click Here

Reply via email to