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

  • SEARCH
  • Home
  • 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 8607321
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T03:19:32+00:00 2026-06-12T03:19:32+00:00

Today I’m working on a project in Java Spring, especially in CONTEXT-SERVLET.xml (context) where

  • 0

Today I’m working on a project in Java Spring, especially in CONTEXT-SERVLET.xml (context) where normally declare a bean to link a .jsp with a Java class or controller (mapping).

Traditional workflow is: a viewA.jsp is linked (mapping) to controller.java (controller) and this controller.java dispatches another viewB.jsp.

Can you link a viewA.jsp to another viewB.Jsp without going through a controller?
How do this in CONTEXT-SERVLET.xml?

  • 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-06-12T03:19:34+00:00Added an answer on June 12, 2026 at 3:19 am

    You can use ParameterizableViewController to redirect a request to jsp file without visiting controller.
    For example
    1. Mapping /welcome.htm to welcomeController

    <bean class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping">
            <property name="mappings">
                <props>
                    <prop key="/welcome.htm">welcomeController</prop>
                </props>
            </property>
    </bean>  
    

    2. Mapping viewName property of welcomeController to WelcomePage

    <bean name="welcomeController" 
                class="org.springframework.web.servlet.mvc.ParameterizableViewController">
            <property name="viewName" value="WelcomePage" />
    </bean>
    

    3. Defining view resolver

    <bean id="viewResolver"
            class="org.springframework.web.servlet.view.InternalResourceViewResolver" >
                <property name="prefix">
                  <value>/WEB-INF/pages/</value>
                </property>
                <property name="suffix">
                  <value>.jsp</value>
                </property>
     </bean>
    

    It will map /welcome.htm to /WEB-INF/pages/welcomePage.jsp.
    Source for more details.

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

Sidebar

Related Questions

Today I just had my first class on Java ee and dynamic web project...
Today I had to define the WIN32_MEAN_AND_LEAN preprocessor macro in a native C++ project
Today, reading Servlet 3.0 specification, I've come across a sentence: We emphasize that this
Today, someone attended me to bad use of the return keyword in Java. I
Today I started work on a small Java app. I have some experience with
Today I had a really great idea for a project, unfortunately there is a
Today I was working on a tab navigation for a webpage. I tried the
today I was trying to use the SnowballAnalyzer on Lucene Java API v3.6.0 but
Today I send someone a xsd file to generate java classes for me. He
Today is my first day working with SQL so please bear with me for

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.