aspose 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 EJB 3 in Action this week in the EJB and other Java EE Technologies 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: 39547
    
  27
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 - updated with new look and Ping home screen widget
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Extracting text from html using htmlparser
 
Similar Threads
creating button using <s:button> - similar to the CSS based button
JEditorPane HTML parsing problem with about CSS
CSS Positioning Issue
using CSS float attribute makes things 'leak' out of their containers ?
Speed up Application Created USing Servlets and JSP