Re: reposting highlighting questions

2011-12-30 Thread Chris Hostetter

: I am new to solr/xml/xslt, and trying to figure out how to display 
: search query fields highlighted in html. I can enable the highlighting 
: in the query, and I think I get the correct xml response back (See 
: below: I search using 'Contents' and the highlighting is shown with 
: strong and /strong. However, I cannot figure out what to add to the 
: xslt file to transform it in html. I think it is a question of defining 

i think you are looking for the disable-output-escaping=yes option on 
your xsl:value-of select=.../ expression to echo out the highlighted 
string.  hard to be sure since you didn't actaully provide any example of 
the XSLT or xpath you are trying to use.


-Hoss


reposting highlighting questions

2011-12-13 Thread Bent Jensen
I am new to solr/xml/xslt, and trying to figure out how to display search query 
fields highlighted in html. I can enable the highlighting in the query, and I 
think I get the correct xml response back (See below: I search using 'Contents' 
and the highlighting is shown with strong and /strong. However, I cannot 
figure out what to add to the xslt file to transform it in html. I think it is 
a question of defining the appropriate xpath(?), but I am stuck. Can someone 
point me in the right direction? Thanks in advance!

 

Here is the result I get back:

?xml version=1.0 encoding=UTF-8 ? 

 http://us.mg4.mail.yahoo.com/neo/ - response

 http://us.mg4.mail.yahoo.com/neo/ - lst name=responseHeader

  int name=status0/int 

  int name=QTime20/int 

 http://us.mg4.mail.yahoo.com/neo/ - lst name=params

  str name=explainOther / 

  str name=indenton/str 

  str name=hl.simple.pre'strong'/str 

  str name=hl.fl*/str 

  str name=wt / 

  str name=hlon/str 

  str name=rows10/str 

  str name=version2.2/str 

  str name=fl / 

  str name=start0/str 

  str name=qcontents/str 

  str name=hl.simple.post'/strong'/str 

  str name=qt / 

  str name=fq / 

  /lst

  /lst

 http://us.mg4.mail.yahoo.com/neo/ - result name=response numFound=1 
start=0

 http://us.mg4.mail.yahoo.com/neo/ - doc

 http://us.mg4.mail.yahoo.com/neo/ - arr name=content

  strStart with the Table of Contents. See if you can find the topic that you 
are interested in. Look through the section to see if there is a resource that 
can help you. If you find one, you may want to attach a Post-it tab so you can 
find the page later. Write down all of the information that you need to find 
out more information about the resource: agency name, name of contact person, 
telephone number, email and website addresses. If you were unable to find a 
resource that will help you in this resource guide, a good first step would be 
to call your local Independent Living Center. They will have a good idea of 
what is available in your area. A second step would be to call or email us at 
the Rehabilitation Research Center. We have a ROBOT resource specialist who may 
be able to assist. /str

  /arr

 http://us.mg4.mail.yahoo.com/neo/ - arr name=doclink

  strrobot.pdf#page=11/str 

  /arr

  str name=heading1CHAPTER 1: How to Use This Resource Guide/str 

  str name=id1-1/str 

  /doc

  /result

 http://us.mg4.mail.yahoo.com/neo/ - lst name=highlighting

 http://us.mg4.mail.yahoo.com/neo/ - lst name=1-1

 http://us.mg4.mail.yahoo.com/neo/ - arr name=content

  strStart with the Table of 'strong'Contents'/strong'. See if you can 
find the topic that you are interested in. Look/str 

  /arr

  /lst

  /lst

  /response

 

  _  

No virus found in this message.
Checked by AVG - www.avg.com
Version: 2012.0.1873 / Virus Database: 2108/4678 - Release Date: 12/13/11



Re: highlighting questions

2011-12-13 Thread Erick Erickson
How to get *what* to display in HTML? The VelocityResponseWriter?
Extracting this content to show in your webapp? How are you displaying
any page at all? You can look at the examples in the VelocityResponseWriter
to get an idea of how to do this with that templating engine.

But the general idea here is that whatever parses your response has to
match the id field in the doc tag with the proper element from
the lstname=highlighting element and mix-n-match them.

Hope that helps
Erick

On Mon, Dec 12, 2011 at 8:03 PM, Bent Jensen bentjen...@yahoo.com wrote:


 I am trying to figure out how to display search query fields highlighted in 
 html. I can enable the highlighting in the query, and I think I get the 
 correct response back (See below: I search using 'Contents' and the 
 highlighting is shown with strong and /strong. However, I can't figure 
 out what to add to the xslt file to display in html. I think it is a question 
 of defining the appropriate xpath(?), but I am stuck. Can someone point me in 
 the right direction? Thanks in advance!


 Here is the result I get back:
 ?xml version=1.0 encoding=UTF-8 ?
 - response
 - lstname=responseHeader
   intname=status0/int
   intname=QTime20/int
 - lstname=params
   str name=explainOther/
   strname=indenton/str
   strname=hl.simple.pre'strong'/str
   strname=hl.fl*/str
   str name=wt/
   strname=hlon/str
   strname=rows10/str
   strname=version2.2/str
   str name=fl/
   strname=start0/str
   strname=qcontents/str
   strname=hl.simple.post'/strong'/str
   str name=qt/
   str name=fq/
   /lst
   /lst
 - resultname=responsenumFound=1start=0
 - doc
 - arrname=content
   strStart with the Table of Contents. See if you can find the topic that 
 you are interested in. Look through the section to see if there is a resource 
 that can help you. If you find one, you may want to attach a Post-it tab so 
 you can find the page later. Write down all of the information that you need 
 to find out more information about the resource: agency name, name of contact 
 person, telephone number, email and website addresses. If you were unable to 
 find a resource that will help you in this resource guide, a good first step 
 would be to call your local Independent Living Center. They will have a good 
 idea of what is available in your area. A second step would be to call or 
 email us at the Rehabilitation Research Center. We have a ROBOT resource 
 specialist who may be able to assist. You can reach Lois Roberts, the “Back 
 On Track …To Success” Mentoring Program Assistant, at 408-793-6426 or email 
 her at lois.robe...@hhs.sccgov.org/str
   /arr
 - arrname=doclink
   strrobot.pdf#page=11/str
   /arr
   strname=heading1CHAPTER 1: How to Use This Resource Guide/str
   strname=id1-1/str
   /doc
   /result
 - lstname=highlighting
 - lstname=1-1
 - arrname=content
   strStart with the Table of 'strong'Contents'/strong'. See if you can 
 find the topic that you are interested in. Look/str
   /arr
   /lst
   /lst
   /response


highlighting questions

2011-12-12 Thread Bent Jensen


I am trying to figure out how to display search query fields highlighted in 
html. I can enable the highlighting in the query, and I think I get the correct 
response back (See below: I search using 'Contents' and the highlighting is 
shown with strong and /strong. However, I can't figure out what to add to 
the xslt file to display in html. I think it is a question of defining the 
appropriate xpath(?), but I am stuck. Can someone point me in the right 
direction? Thanks in advance!


Here is the result I get back:
?xml version=1.0 encoding=UTF-8 ? 
- response
- lstname=responseHeader
  intname=status0/int 
  intname=QTime20/int 
- lstname=params
  str name=explainOther/ 
  strname=indenton/str 
  strname=hl.simple.pre'strong'/str 
  strname=hl.fl*/str 
  str name=wt/ 
  strname=hlon/str 
  strname=rows10/str 
  strname=version2.2/str 
  str name=fl/ 
  strname=start0/str 
  strname=qcontents/str 
  strname=hl.simple.post'/strong'/str 
  str name=qt/ 
  str name=fq/ 
  /lst
  /lst
- resultname=responsenumFound=1start=0
- doc
- arrname=content
  strStart with the Table of Contents. See if you can find the topic that you 
are interested in. Look through the section to see if there is a resource that 
can help you. If you find one, you may want to attach a Post-it tab so you can 
find the page later. Write down all of the information that you need to find 
out more information about the resource: agency name, name of contact person, 
telephone number, email and website addresses. If you were unable to find a 
resource that will help you in this resource guide, a good first step would be 
to call your local Independent Living Center. They will have a good idea of 
what is available in your area. A second step would be to call or email us at 
the Rehabilitation Research Center. We have a ROBOT resource specialist who may 
be able to assist. You can reach Lois Roberts, the “Back On Track …To Success” 
Mentoring Program Assistant, at 408-793-6426 or email her at 
lois.robe...@hhs.sccgov.org/str 
  /arr
- arrname=doclink
  strrobot.pdf#page=11/str 
  /arr
  strname=heading1CHAPTER 1: How to Use This Resource Guide/str 
  strname=id1-1/str 
  /doc
  /result
- lstname=highlighting
- lstname=1-1
- arrname=content
  strStart with the Table of 'strong'Contents'/strong'. See if you can 
find the topic that you are interested in. Look/str 
  /arr
  /lst
  /lst
  /response

Re: Highlighting questions

2010-05-27 Thread Erik Hatcher
Just set the pre and post tags to be empty strings and you'll get the  
result you want, I think.  No?


Erik

On May 26, 2010, at 8:36 PM, Blargy wrote:



What are the correct for settings to get highlighting excerpting  
working?


Original Text: The quick brown fox jumps over the lazy dog
Query: jump
Result:  fox jumps over 

Can you do something like the above with the highlighter or can it  
only

surround matches with pre and post tags? Can someone explain what
mergeContinuous does?

Thanks.
--
View this message in context: 
http://lucene.472066.n3.nabble.com/Highlighting-questions-tp846628p846628.html
Sent from the Solr - User mailing list archive at Nabble.com.




Highlighting questions

2010-05-26 Thread Blargy

What are the correct for settings to get highlighting excerpting working?

Original Text: The quick brown fox jumps over the lazy dog
Query: jump
Result:  fox jumps over 

Can you do something like the above with the highlighter or can it only
surround matches with pre and post tags? Can someone explain what
mergeContinuous does? 

Thanks.
-- 
View this message in context: 
http://lucene.472066.n3.nabble.com/Highlighting-questions-tp846628p846628.html
Sent from the Solr - User mailing list archive at Nabble.com.