TAGS :Viewed: 10 - Published at: a few seconds ago

[ How to implement Jquery UI Themeroller in NetBeans IDE ]

I'm developing using JSF 2.2 and using PrimeFaces as my framework.

After downloading the customized theme from http://jqueryui.com/themeroller/, what I downloaded was a zip file, the extracted files looked like this:

image

I tried following a tutorial from http://www.mkyong.com/jsf2/primefaces/create-a-custom-theme-in-primefaces/ but the files doesn't match to his tutorial so I'm not really exactly sure which CSS to use.

After some googling, I found https://osnode.themeroller.com but alias, the server resource seems to be unavailable too.

I also tried implementing into my IDE folder directly, but the CSS didn't follow.

I'm a beginner at JSF so I'm not really sure of the way to implement this. Would really appreciate any alternative ideas to getting this right!

If there are any information that I'm missing in to include in this question, please let me know too.

Answer 1


This works for me, and I find it the far easiest way:

  1. Create theme with themeroller
  2. Click download theme. Deselect all components and click download.
  3. Convert the Themeroller theme to a Primefaces theme here. Upload the zip and click Create theme jar. For this example I gave it the name test. Click the download button.
  4. Unzip the downloaded jar-file (renaming to zip might help). In the extracted META-INF folder navigate to the folder primefaces-test (in my example). Copy this folder to the resources-folder in Netbeans:

enter image description here

  1. Put the following in web.xml:
<context-param>
   <param-name>primefaces.THEME</param-name>
   <param-value>test</param-value>
</context-param>

Answer 2


Hope this link helps: Create A Custom Theme In PrimeFaces

I always do the 1, 2, 3 and 6 steps and then the "alternative way" (you can copy the entire “primefaces-yourtheme” folder, and put it directly into the JSF resources folder).

Hope this will help you. Good luck!