On Mon, Jun 28, 2010 at 11:54 AM, Carles Barrobés <cbarro...@isigma.es> wrote: > I'm parsing an XHTML response with DomRepresentation, and it generates an > exception: > > > Exception in thread "main" java.lang.RuntimeException: java.io.IOException: > Server returned HTTP response code: 503 for URL: > http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd > at > org.restlet.ext.xml.XmlRepresentation.internalEval(XmlRepresentation.java:556) > at > org.restlet.ext.xml.XmlRepresentation.getNodes(XmlRepresentation.java:437) > at > es.isigma.portasigma.client.ClientExample.main(ClientExample.java:32) > > > This is due to the fact that restlet's DomRepresentation is attempting DTD > validation even if I explicitly disable it in my client code ( > doc.setValidatingDtd(false) ):
This isn't because of DTD validation. It is because the parser is reading the external subset. You (or someone) need to allow you to turn off retrieving and parsing the external subset. You could possibly do that by setting the EntityResolver instance. --Alex Milowski ------------------------------------------------------ http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2626841