This commit is contained in:
Lucio Lelii 2008-10-08 08:49:23 +00:00
parent e4f1b6ea6a
commit b841833fed
1 changed files with 5 additions and 1 deletions

View File

@ -77,8 +77,12 @@ public class ProfileResource extends GCUBEWSResource {
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
factory.setNamespaceAware(true);
DocumentBuilder builder = factory.newDocumentBuilder();
StringReader reader = new StringReader(writer.toString().substring(writer.toString().indexOf("?>")+2, writer.toString().length()));
InputSource source = new InputSource(reader);
InputSource source = new InputSource();
source.setEncoding("UTF-8");
source.setCharacterStream(reader);
System.out.println("-----------"+source.getCharacterStream());
dom =builder.parse(source);
} catch (Exception e1) {
throw new ResourceException(e1);