java.io.IOException: Server returned HTTP response code: 503 for URL: http://www.w3.org/TR/xhtml1/DT

Posted by JBristow on Stack Overflow See other posts from Stack Overflow or by JBristow
Published on 2010-03-23T18:27:39Z Indexed on 2010/03/23 18:33 UTC
Read the original article Hit count: 448

Filed under:
|
|
|

In the following code:

private Document transformDoc(Source source) throws TransformerException, IOException {
    TransformerFactory factory = TransformerFactory.newInstance();

    Transformer transformer =
            factory.newTransformer(new StreamSource(xsltResource.getInputStream()));
    JDOMResult result = new JDOMResult();
    transformer.transform(source, result);
    return result.getDocument();
}

I get this exception:

java.io.IOException: Server returned HTTP response code: 503 for URL: http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd

The XHTML I'm translating over via xsl is:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
  <title>Terms and Conditions</title>
</head>
<body>
  <div>Test Content</div>
</body>
</html>

How do I stop the xalan transformer from phoning home?

© Stack Overflow or respective owner

Related posts about XHTML

Related posts about xalan