Reputation: 13
I import my css file and javascript files in index.xhtml
<script type="text/javascript" src="resource/js/bag.js"></script>
My project works like this in http://localhost:8084/Proje1/ . But when i open http://localhost:8084/Proje1/faces/index.xhtml this url, doesn't work. It doesn't find css file and jquery files. How can i fix this. Thank you.
Upvotes: 0
Views: 78
Reputation: 377
Place your resource folder under WebContent, and replace your <script>
import with this:
<script src="#{request.contextPath}/resource/js/bag.js"></script>
Upvotes: 1