I\'m working on a project using JSF/Facelets. I want to do some CSS changes on my View XHTML, but nothing happen when i deploy my web application in my Tomcat Server. I\'ve
Add resources folder under the WebContent
and inside resources create css folder
then access the files like this
h:outputStylesheet library="css" name="myNewStylesFile.css" target="head" under h:head section that you did not add
The <h:outputStylesheet> (and <h:outputScript>) requires a <h:head>, but you've there a <head>. Fix it accordingly.
<h:head>
<h:outputStylesheet name="css/styles.css" />
</h:head>
Further, you need to ensure that the css/styles.css file is been placed in the /resources subfolder of the public webcontent.
WebContent
|-- resources
| `-- css
| `-- styles.css
:
As to your attempt to use the library attribute, be careful with this, using library="css" isn't entirely correct in this context. See also: What is the JSF resource library for and how should it be used?