Hi, I developed a custom converter to highlight certain terms in a string that is displayed with an <h:outputText> tag.

Here's a sample code to illustrate how it works:

<h:outputText value="#{myBean.description}">
   <q:stringMatcher match="#{myBean.queryString}" />
</h:outputText>


myBean.queryString property is populated by an inputText in the same page.

So I would like to highlight matching words depending on what the user is searching...

The first time I access the page everything works well, but as soon as I submit the page, nothing gets highlighted.
I'm sure myBean.queryString is not null, because in the same page I'm displaying it...

If it could be interesting for someone I could post the converter source code.

Thanks,
Ennio

Reply via email to