Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5967113
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T19:53:50+00:00 2026-05-22T19:53:50+00:00

I have all the jsp files used by a webapp in a separate folder

  • 0

I have all the jsp files used by a webapp in a separate folder named jsp. I tried reference all the jsp files in the web.xml by the following way. But doesn’t work. What could be the problem?

**

<servlet>
<servlet-name>Jsps</servlet-name>
<jsp-file>/jsp/path/</jsp-file>
</servlet>

<servlet-mapping>
<servlet-name>Jsps</servlet-name>
<url-pattern>/*.jsp<url-pattern>
</servlet-mapping>

**

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T19:53:50+00:00Added an answer on May 22, 2026 at 7:53 pm

    You cannot group jsps together under one servlet. If jsp is to be declared as a servlet, Each jsp should be defined as one servlet. For ex:

    <servlet>
    <servlet-name>Jsp1</servlet-name>
    <jsp-file>/jsp/path/myjsp.jsp</jsp-file>
    </servlet>
    
    <servlet-mapping>
    <servlet-name>Jsp1</servlet-name>
    <url-pattern>/myjsp.jsp<url-pattern>
    </servlet-mapping>
    
    <servlet>
    <servlet-name>Jsp2</servlet-name>
    <jsp-file>/jsp/path/myjsp2.jsp</jsp-file>
    </servlet>
    
    <servlet-mapping>
    <servlet-name>Jsp2</servlet-name>
    <url-pattern>/myjsp2.jsp<url-pattern>
    </servlet-mapping>
    

    If your requirement if just to access jsps , you do not need any servlet definitions or servlet mappings. Access it directly using /jsp/path/myjsp.jsp path

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Once I have all the files I require in a particular folder, I would
I currently have the following includes at the top of all of my jsp
I have a folder and it's name is v3 . There are jsp files
I have all the forms in one folder and all the code modules in
I have all the web pages of a website. My task is to change
We have 600 jsp files and I need to find out where we are
I have an apache webserver that is used to serve php and static web
I have some code within struts.xml like: <action name=viewApplicationPDF class=com.xxx.abc.web.action.XApplicationPDFAction> <result name=success>/WEB-INF/templates/xApplication.jsp</result> </action> I
I have simple web application based on JSP. Root of application looks like this:
I have a webapp in Tomcat with a main JSP file that includes another

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.