Yes, the getBestFragment() returns the matched fragment "fragmentcount" numbers each separated with the "fragmentseparator". what exactly you mean by "highlight the searched word in the document." what is this document??? first let us know what exactly you want to with the search results.
--KK On Thu, May 28, 2009 at 12:23 PM, Ritu choudhary <ritu.it...@gmail.com>wrote: > The output i want is to show the text i searched let's say "search" in the > document where it occured. Like this: > > > the text i want to search is this and it should be highlighted as this . > Search currently is giving just the word "search". The result i want is to > highlight the searched word in the document. How can i do that. Doesn't > getBestFragment() return the whole fragment(or the document) in which the > searched word occur or does it give just the word. How can i achieve this? >