Skip to main content

Blog Archive for mriem during December 2013

Occasionally, users have the need to override the version of JSF included in the application server by bundling a different version of JSF with their application. If you are trying to use CDI in such a scenario, you might have noticed it does not work. Is there a way out? Yes, there is, by including a small JAR and some configuration in your web application you can make this scenario work. Add...
To make it possible to debug the view tree the JSF runtime has a debug component (ui:debug) that you can use. What is the best way to do this? Add the ui:debug component to the bottom of your page and activate it only in Development mode. This makes it available when the application needs to be debugged, but it does not put a burden on a Production application.   <ui:debug rendered=...
How do you convert a date in JSF? The example below outputs the date using the long date style <?xml version='1.0' encoding='UTF-8' ?><!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml"      xmlns:h="http://java.sun.com/jsf/html"      xmlns:f="http://java.sun.com/jsf/...
If you have ever wondered which version of Mojarra is running on the container you can determine what version is running using a simple piece of code. How? The following code snippet shows you how!   FacesContext.getCurrentInstance().getClass().getPackage().getImplementationVersion() And that is it. Enjoy!
Hurray, 50 JSF tips! For your convenience I have prepared a JSF tips bitly bundle that links back to them all. See http://bitly.com/bundles/o_7q05ovp05f/2 And that is it. Enjoy!
Ever wondered how you would use a composite component within a composite component? Or is it not possible? It most certainly is possible, so lets see how! First we define level 2 (the deepest nesting) <?xml version='1.0' encoding='UTF-8' ?><!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml"      xmlns:h="...