Cant see why you would put highlighting in a separate field. Isn't it the idea to highlight the content found in a search result like google would do ?
Lee On 10 Mar 2010, at 15:52, Joe Calderon wrote: > no, thats not the case, see this example response in json format: > { > "responseHeader":{ > "status":0, > "QTime":0, > "params":{ > "indent":"on", > "q":"title_edge:fami", > "hl.fl":"title_edge", > "wt":"json", > "hl":"on", > "rows":"1"}}, > "response":{"numFound":18,"start":0,"docs":[ > { > "title_id":1581, > "title_edge":"Family", > "num":4}] > }, > "highlighting":{ > "1581":{ > "title_edge":["<em>Fami</em>ly"]}} > > > > see how the highlight info is separate from the results? > > On Wed, Mar 10, 2010 at 7:44 AM, Lee Smith <l...@weblee.co.uk> wrote: >> Im am getting results no problem with the query. >> >> But from what I believe it should wrap <em/> around the text in the result. >> >> So if I search ie Andrew within the return content Ie would have the >> contents with the word <em>Andrew</em> >> >> and hl.fl=attr_content >> >> Thank you for you help >> >> Begin forwarded message: >> >>> From: Joe Calderon <calderon....@gmail.com> >>> Date: 10 March 2010 15:37:35 GMT >>> To: solr-user@lucene.apache.org >>> Subject: Re: Highlighting >>> Reply-To: solr-user@lucene.apache.org >>> >>> just to make sure were on the same page, youre saying that the >>> highlight section of the response is empty right? the results section >>> is never highlighted but a separate section contains the highlighted >>> fields specified in hl.fl= >>> >>> On Wed, Mar 10, 2010 at 5:23 AM, Ahmet Arslan <iori...@yahoo.com> wrote: >>>> >>>> >>>>> Yes Content is stored and I get same >>>>> results adding that parameter. >>>>> >>>>> Still not highlighting the content :-( >>>>> >>>>> Any other ideas >>>> >>>> What is the field type of attr_content? And what is your query? >>>> >>>> Are you running your query on another field and then requesting snippets >>>> from >>>> attr_content? >>>> >>>> q:attr_content:somequery&hl=true&hl.fl=attr_content&hl.maxAnalyzedChars=-1 >>>> should return highlighting. >>>> >>>> >>>> >>>> >> >>