0

i am not able to print a simple welcome program in eclipse mars using jsp. my project name is mayank and i have placed index.jsp inside mayank/webcontent. here is my code:

index.jsp

<html>
<head>
<title> hello</title>
</head>
<body>
<%="welcome to jsp" %>
</body>
</html>

when i try to run apache tomcat server it always show 404 error. can someone please help me why this problem is occurring again and again

2 Answers2

2

Please check the url once and also please ensure that you will create the jsp page in the webContent folder.You can specify the jsp file in the web.xml as your first page to open when application load.

 <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
  </welcome-file-list>
Panky031
  • 425
  • 1
  • 5
  • 14
1

What url are you calling (and which port is your server configured to use)? What does your project hierarchy look like? (for instance, what is the path to your index.jsp file?)

Related:

Community
  • 1
  • 1
Kristoffer Bohmann
  • 3,986
  • 3
  • 28
  • 35