I was looking to install PrimeFaces Extensions into my PrimeFaces project, but I failed to find any website that mention how PrimeFaces Extensions install into a PrimeFaces project.
Then I copied the primefaces-extensions-0.6.2.jar into my PrimeFaces project and start the Tomcat.
Thus, I have to try and error by myself.
First, I opened up my PrimeFaces project that previously created with JBoss Tools.
Unfortunately, the application failed to start and showing the following error.
Caused by: java.lang.ClassNotFoundException: org.apache.commons.lang3.StringEscapeUtils
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1714)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at com.sun.faces.util.Util.loadClass(Util.java:273)
at com.sun.faces.config.processor.AbstractConfigProcessor.loadClass(AbstractConfigProcessor.java:311)
at com.sun.faces.config.processor.FaceletTaglibConfigProcessor.processFunctions(FaceletTaglibConfigProcessor.java:616)
... 14 more
It's required me to add in commons-lang3-3.1.jar into the project and restart again.
this time I was successfully start the Tomcat server, and tested the PrimeFaces Extensions with the following code.
Output:
1. primefaces-extensions-0.6.2.jar
2. commons-lang3-3.1.jar
It should works!
this time I was successfully start the Tomcat server, and tested the PrimeFaces Extensions with the following code.
<pe:inputNumber id="input2" value="#{testBean.numberValue}"
symbol=" CHF" symbolPosition="s"
decimalSeparator="," thousandSeparator=".">
<p:ajax event="blur" />
</pe:inputNumber>
Output:
Conclusion:
copy the following jar into the existing PrimeFaces project and test the PrimeFaces Extensions again1. primefaces-extensions-0.6.2.jar
2. commons-lang3-3.1.jar
It should works!
Related PrimeFaces installation:
- How to install PrimeFaces with JBoss Tools
- How to install upgrade to PrimeFaces 4
- How to enable CKEditor in PrimeFaces Extension
- How to install PrimeFaces with JBoss Tools
- How to install upgrade to PrimeFaces 4
- How to enable CKEditor in PrimeFaces Extension
Done!!
Very good solution .. =)
ReplyDeleteThank you very much my friend. It worked for me!.
ReplyDelete