6 Replies Latest reply on Jul 11, 2008 8:37 AM by damatrix

    Allow user to Dynamically change skin like RichFaces demo

    sansaric

      Hello,
      I recently started using RichFaces and have gone through the documentation and users forum. However, I still can't figure out how to dynamically change skins within an application like is done is the RichFaces demo. I am only able to change skins globally as described in the doc by modifying the skin context parameter definition in web.xml:
      <context-param>
      <param-name>org.ajax4jsf.SKIN</param-name>
      <param-value>classic</param-value>
      </context-param>

      I tried
      <context-param>
      <param-name>org.ajax4jsf.SKIN</param-name>
      <param-value>#{skinBean.skin}</param-value>
      </context-param>
      where skinBean is a managed Bean declared in faces-config.xml,and similar to that used in the demo but I get an error stating that the value of '#{skinBean.skin}' could not be obtained.

      Can someone please tell me what is the best way to allow users of my application to change skins dynamically ?

      Thanks in advance for your help