You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Developer <bb...@gmail.com> on 2014/02/18 00:53:22 UTC

Escape \\n from getting highlighted - highlighter component

Hi,

When searching for a text like 'talk n text' the highlighter component also
adds the <em> tags to the special characters like \n. Is there a way to
avoid highlighting the special characters?

\\r\\n Family Messaging

 is getting replaced as 

\\r\\<em>n</em> Family Messaging 



--
View this message in context: http://lucene.472066.n3.nabble.com/Escape-n-from-getting-highlighted-highlighter-component-tp4117895.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Escape \\n from getting highlighted - highlighter component

Posted by "T. Kuro Kurosaka" <ku...@healthline.com>.
Your search expression means 'talk' OR 'n' OR 'text'.
I think you want to do a phrase search. To do that, quote the whole 
thing with double-quotes "talk n text", if you are using one of the Solr 
standard query parsers.


On 02/17/2014 03:53 PM, Developer wrote:
> Hi,
>
> When searching for a text like 'talk n text' the highlighter component also
> adds the <em> tags to the special characters like \n. Is there a way to
> avoid highlighting the special characters?
>
> \\r\\n Family Messaging
>
>   is getting replaced as
>
> \\r\\<em>n</em> Family Messaging

Kuro