Win a copy of The Journey To Enterprise Agility this week in the Agile and Other Processes forum! And see the welcome thread for 20% off.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
Sheriffs:
  • Paul Clapham
  • Junilu Lacar
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Ganesh Patekar
  • Tim Moores
  • Pete Letkeman
  • Stephan van Hulst
Bartenders:
  • Carey Brown
  • Tim Holloway
  • Joe Ess

Problem running a simple JSF application  RSS feed

 
Ranch Hand
Posts: 280
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All, I am a newbie to JSF and I am trying to run a simple application in JSF. I am using JBoss 4.2.2GA application server.

faces-config.xml


index.jsp


web.xml


I have the following problem :
1) When I go to the url http://localhost:8080/jsfapplication it says :


description The requested resource (/jsfapplication/jsp/inputname.jsp) is not available.



My directory structure is as follows :
JSF Application
-->WEB-INF/src/java
-->WEB-INF
-->jsp
--greeting.jsp
--inputname.jsp
-->lib
-->src
faces-config.xml
web.xml
index.jsp
message.properties

When I give the jspforward in index.jsp like this
<jsp:forward page="/WEB-INF/jsp/inputname.jsf"/>
it works ..........

Please tell me where i am going wrong and please clear my concepts... I would be very thankfull to you.... Thanks in advance .....
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dude, I'm doing a huge thing in my new job using JSF but (tell no one...) I'm a newbie in jsf! I'm terrify with the idea of getting fired, but i think i know whatś wrong with your configuration:

Have you seen this code in your web.xml?

<welcome-file-list>
<welcome-file>faces/welcomeJSF.jsp</welcome-file>
</welcome-file-list>
</web-app>



Maybe that's it! If you can't make it work i sugest you start using Netbeans 6, it's easier this way!
 
Siddharth Bhargava
Ranch Hand
Posts: 280
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This dosen't seem to work ... When I put the jsp folder outside of WEB-INF it works... Please clear my concepts .....
 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi dude
In the index.jsp you included a forward to "/pages/inputname.jsp". Here the "/" before pages means the root of the web application i.e it locates upto your /Webcontent folder. hence by telling /pages/inputname.jsp you mean ../Webcontent/pages/inputname.jsp.. so only, when you moved your pages folder from WEB-INF to directly under /Webcontent it worked.

Regards,
Balaji N
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!