Java & XSLT
Hello,
first of all, please excuse my not so great english,
i am trying to do a filter that will take the processed jsp file (the jsp makes a XML file), and then pass it on a XSLT processor
I have a filter that does something like:
TransformerFactory transformerfactory = TransformerFactory.newInstance();
Transformer transformer = transformerfactory.newTransformer(new javax.xml.transform.stream.StreamSource("teste.xsl t"));
transformer.transform(xmlSource, new StreamResult(printwriter));
The xmlSource comes from:
String str = new String(wrapper.getBuffer());
StringReader sr = new StringReader(str);
StreamSource xmlSource = new StreamSource(sr);
The wrapper is a BufferedResponseWrapper i found on the internet
The problem is i keep getting this error that says:
org.xml.sax.SAXParseException: Premature end of file.
I don't know if this is enough info, but if you could please help me
thanks
|