I am using JSF 2.0 and have defined property javax.faces.FACELETS_SKIP_COMMENTS
to skip comments in JSF code because there is a lot of other code, deveploping comments etc. But I need to print some HTML comments into client's browser eg. for defining alternative conditioned stylesheet for other browsers.
Please is there any way how to do it? Because all my attempts failed.
Comments are placed inside <! -- --> in XHTML MP. This is the same as HTML and WML 1.
This is crude but it does work (under JSF 1.2 anyway not tested in 2)
<h:outputText value="<!--" escape="false" /> My comment <h:outputText value="-->" escape="false" />
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With