Spring, Prime Faces application not showing CSS when deploying to Heroku
I am working with Spring 3.1.3, Prime Faces 3.4.2, Hibernate 3.6.8 and
Pretty Faces 2.0.4.
The CSS is showing when I deploy the app in a local Server (Apache Tomcat
7), but when I deploy the same project to Heroku the CSS is not showing.
This is how I input the CSS in my main.xhtml template file:
<h:outputStylesheet library="css" name="bootstrap.css" />
<h:outputStylesheet library="css" name="custom.css" />
This is the result in the html source (local server):
<link type="text/css" rel="stylesheet"
href="/evaluation-cloud/javax.faces.resource/theme.css.jsf?ln=primefaces-cupertino"
/>
<link rel="stylesheet" media="screen" type="text/css"
href="/evaluation-cloud/javax.faces.resource/bootstrap.css.jsf?ln=css" />
<link rel="stylesheet" media="screen" type="text/css"
href="/evaluation-cloud/javax.faces.resource/custom.css.jsf?ln=css" />
<link rel="stylesheet" media="screen" type="text/css"
href="/evaluation-cloud/javax.faces.resource/primefaces.css.jsf?ln=primefaces"
/>
This is the result in the html source when deployed to Heroku
<link type="text/css" rel="stylesheet"
href="//javax.faces.resource/theme.css.jsf?ln=primefaces-cupertino" />
<link rel="stylesheet" media="screen" type="text/css"
href="//javax.faces.resource/bootstrap.css.jsf?ln=css" />
<link rel="stylesheet" media="screen" type="text/css"
href="//javax.faces.resource/custom.css.jsf?ln=css" />
<link rel="stylesheet" media="screen" type="text/css"
href="//javax.faces.resource/primefaces.css.jsf?ln=primefaces" />
Notice the '//' in the href
I don't know why this is happening. If someone have experienced the same
issue please help me.
Thank you.
No comments:
Post a Comment