• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

simpleJSP can't run

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I was trying to run a simple JSP.
----
<%@page import="java.util.Date"%>
<html>
<body>
The current time is <%=new Date().toString() %>
</body>
</html>
-----
then I save it as simpleJSP.jsp and place it in the root directory C:\Java\Chapter11\JSPExample\simpleJSP.jsp
Then I deploy the JSPExamples application in Tomcat by adding the following entry to my tomcat directory\conf\server.xml
-----
<Context path =/JSPExamples" docBase="c:\Java/Chapter11/JSPExamples"></Context>
------
Then I restart my Tomcat and point the browser to http://localhost:8080/JSPExamples/simpleJSP.jsp but the file is not found. Can anyone explain this to me and how can I make it run?
Thanks in advance
 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hai vivi santa,
hope this will help you.
change the following context tag:
<Context path =/JSPExamples" docBase="c:\Java/Chapter11/JSPExamples"></Context>
as:
<Context path ="/JSPExamples"
docBase="c:\Java\Chapter11\JSPExamples"></Context>
all the best
give reply(rbalapanuru@citl-org.com)

------------------
Regards
Ravindranath
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic