You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.
| Online: | 12 Members of 9401 |
| Forum: Seam Users |
14. Jul 2008, 05:35 America/New_York | Link |
Hello,
I am posting this because others might find it useful.
myPage.xhtml:
<h:selectOneMenu value="#{themeSelector.theme}" valueChangeListener="#{themeSelector.select}" onchange="submit()">
<f:selectItems value="#{themeSelector.themes}"/>
</h:selectOneMenu>
web.xml:
<context-param>
<param-name>org.richfaces.SKIN</param-name>
<param-value>#{theme.skin}</param-value>
</context-param>
components.xml:
xmlns:theme="http://jboss.com/products/seam/theme"
http://jboss.com/products/seam/theme http://jboss.com/products/seam/theme-2.0.xsd
<theme:theme-selector cookie-enabled="true" theme="emeraldTown">
<theme:available-themes>
<value>blueSky</value>
<value>emeraldTown</value>
</theme:available-themes>
</theme:theme-selector>
blueSky.properties:
skin=blueSky
emeraldTown.properties:
skin=emeraldTown
5 Replies: | ||
|---|---|---|
I have done that in this way you described..but I get the following failure: 14:41:09,655 ERROR [AjaxPhaseListener] Exception on get current Skin org.richfaces.skin.SkinNotFoundException: Skin with name skin not found at org.richfaces.skin.SkinFactoryImpl.loadProperties(SkinFactoryImpl.java:366) at org.richfaces.skin.SkinFactoryImpl.buildSkin(SkinFactoryImpl.java:300) at org.richfaces.skin.SkinFactoryImpl.getSkinByName(SkinFactoryImpl.java:126) at org.richfaces.skin.SkinFactoryImpl.getSkin(SkinFactoryImpl.java:141) at org.ajax4jsf.event.AjaxPhaseListener.beforePhase(AjaxPhaseListener.java:119) at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:222) Skin with name skin not found (but Skins are exists!) Any ideas? |
||
Worked with following in web.xml:
<context-param> <param-name>org.richfaces.SKIN</param-name> <param-value>#{themeSelector.theme}</param-value> </context-param> and additional properties file called skin.properties |
||
This seems to work fine to begin with, but after a few times, I get an infinite redirect loop and the following error org.richfaces.skin.SkinNotFoundException: Name for current Skin calculated as null The application hangs and the only way is to remove the skinning in components.xml. (add a default in web.xml) |
||
I am getting the same exception, Did anyone got this thing working ?? |
The only limit to our realization of tomorrow will be our doubts of today. FDR