JSF: How to allow extension # {...} not to escape?

I have a custom EL function (defined in myfunctions.taglib.xml ) that returns a piece of HTML, I want to copy it to the end,

 <f:verbatim> #{mylib:generateHtml()} </f:verbatim> 

however, the decomposition # {...} is always escaped. How to make him not run away?

+4
source share
2 answers

I believe there is an option for escape characters with verbatim.

 <f:verbatim escape="#{boolean}" /> 
0
source

Use <h:outputText escape="false" /> . <f:verbatim> serves a completely different purpose especially for JSP views and is dangerous for Facelets and is deprecated in JSF 2.0.

 <h:outputText value="#{bean.html}" escape="false" /> 
+7
source

Source: https://habr.com/ru/post/1347661/


All Articles