File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other Java Products and Servers and the fly likes Extracting text from html using htmlparser Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Products » Other Java Products and Servers
Bookmark "Extracting text from html using htmlparser" Watch "Extracting text from html using htmlparser" New topic
Author

Extracting text from html using htmlparser

dhriti joshi
Ranch Hand

Joined: Aug 13, 2002
Posts: 82
I have an html from which I want to etract an included html,to mark the html I have put a starting and an end tag say <here> and </here>.
how do I exract all the text in between this html.

example is
<html>
<head>
<here>
abc
<div>def<div>
</here>
</head>
</html>

how do I extract string "abcdef",using the HTML parser.

Thanks in advance,
Dhriti.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
What do you mean by "the HTML parser" - this one http://htmlparser.sourceforge.net/? If so, then there are several sample programs on the web site that should get you started; StringExtractor in particular looks promising.


Ping & DNS - my free Android networking tools app
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Extracting text from html using htmlparser