xerces-j-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@cyberspace.org
Subject HTMLDocument howto,..(urgent)
Date Thu, 11 Apr 2002 11:12:04 GMT

How do we get HTMLDocument for a html, the following doesnt seem to work:

 DOMParser domp = new DOMParser();
 domp.parse(new InputSource(htmlfile));
 Document d = domp.getDocument();
 HTMLDocument hd = (HTMLDocument)d;
 System.out.println ("HTML TITLE: "+hd.getTitle());
 System.out.println ("HTML body: "+ hd.getBody().getNodeValue());

   on the html

   <title>title text</title>
   <body>body text </body>


To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org

View raw message