Re: [Htmlparser-user] help in htmlparser(I need to retrieve Snippets)
Brought to you by:
derrickoswald
From: Somik R. <so...@ya...> - 2003-02-17 19:06:46
|
> I need to get only "Title and snippets(summary)" > from Google search page. Write your own visitor. The visitor should override visitTag(). Check if the tag is a HTMLTitleTag, and if it is - you have the title contents. To get snippets, override visitStringNode(), and collect all the string data. To clean them up, use HTMLParserUtils.removeEscapeCharacters(). Check http://htmlparser.sourceforge.net/docs/index.php/LinkExtraction (point 3), for an example of writing your own visitor. Regards, Somik __________________________________________________ Do you Yahoo!? Yahoo! Shopping - Send Flowers for Valentine's Day http://shopping.yahoo.com |