RE: [xsl] disable-output-escaping="yes" and crimson JDK1.4.1 parser does not work (or is disabled)

Subject: RE: [xsl] disable-output-escaping="yes" and crimson JDK1.4.1 parser does not work (or is disabled)
From: "Andrew Milkowski" <amilkowski@xxxxxxxxxxx>
Date: Tue, 7 Jan 2003 11:32:24 -0500
FYI.. this is what I wind up doing.. used (post-transform) works great! once
again thanks for all the help

used these two lines in the code below
{
data =  replaceAll(data, "&amp;lt;", "&lt;" );
data =  replaceAll(data, "&amp;gt;", "&gt;" );
}

in the context of

		boolean exception = false;
 		String exceptionMessage = null;

		TransformerFactory factory = null;
		Transformer transformer = null;
		StringWriter writer = new StringWriter();
		StreamResult result = null;

		String data = null;
		InputStream inputStream = null;

 		try {
            factory = TransformerFactory.newInstance();
            transformer = factory.newTransformer(XSLSource);
			result = new StreamResult();
			result.setWriter(writer);
			transformer.transform(genericGraphSession.getXMLSource(), result);
            data = "<?xml version=\"1.0\"?>";
 			data += "<!DOCTYPE chart SYSTEM \"Chart.dtd\">";
        	data += writer.toString();
/* substitute &amp;&lt; and &amp;&gt; header and footer attributes for < and
> */
        	data =  GraphUtil.replaceAll(data, "&amp;lt;", "&lt;" );
        	data =  GraphUtil.replaceAll(data, "&amp;gt;", "&gt;" );
        	inputStream = new ByteArrayInputStream(data.getBytes("UTF-8"));
        } catch (Exception e) {
 			exception = true;
 			exceptionMessage = e.getMessage();
 		} finally {
 			factory = null;
        	transformer = null;
        	result = null;
 			try {
 				writer.close();
 				writer = null;
 				XSLSource.getInputStream().reset();
 			} catch (IOException ioe) {
 				if (!exception) {
 					exception = true;
 					exceptionMessage = exceptionMessage;
 				}
 			}
 			if (exception) {
      			throw new GenericGraphException(this.toString(),
      											"public List loadXMLDocumentToList(GenericGraphSession
genericGraphSession) throws GenericGraphException",
      											exceptionMessage);
 			}
 			return inputStream;
 		}

-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of David
Carlisle
Sent: Tuesday, January 07, 2003 5:25 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [xsl] disable-output-escaping="yes" and crimson JDK1.4.1
parser does not work (or is disabled)



> is disable-output-escaping disabled in the crimson JDK1.4.1, and if so,
how
> do I turn it on

you are generating an attribute value and disable-output-escaping has no
effect on attribute values.

<xsl:output method="html"/>

this declares you are generating html but...

<chart name="MFChart" width="900" height="580">
	    		<header>

your result has <chart and <header elements which are not html.

What are you trying to produce? If you specified what you were trying to
generate rather than the xslt you were trying to use, someone could
probably offer more help.

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread