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 3273770
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T18:58:01+00:00 2026-05-17T18:58:01+00:00

I am just getting started on web app development. I have an index.jsp that

  • 0

I am just getting started on web app development. I have an index.jsp that has just ONE line.

< jsp:forward page="landing.do?"/>

What does

  • the above line do?

  • page="landing.do?" actually refer to?

  • what does the question mark "?" next to "landing.do?" signify?

As Bozho rightly pointed out, a servlet called "action" is mapped to handle "*.do" in my web.xml (as shown below).

<servlet-mapping>

    <servlet-name>action</servlet-name>

    <url-pattern>*.do</url-pattern>

</servlet-mapping>

Now

How do I find out what the servlet "action" corresponding to "landing.do" actually does?

Thanks.

  • 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-17T18:58:01+00:00Added an answer on May 17, 2026 at 6:58 pm

    The <jsp:forward> forwards a client request to the url declared on the page attribute.

    I also need to mention that in your example, you should have a / as first character inside your page declaration, if you want to specify a relative URL, i.e.:

    This, in effect, is translated as a redirection to (if localhost)

    http://localhost:8080/MyAPP/landing.do? (yours would have been translated to http://localhost:8080/MyAPPLanding.do?)

    The ? allows you to append application/x-www-form-urlencoded parameters into your declaration.

    More info here.


    To know what landing.do does, do the following:

    • Go to your struts-config.xml (found in WEB-INF folder in your project) file and find any action (<action>) that a path="/landing") attribute.
    • Once you find your action, there’s an attribute called type (inside that action). The type is a the class name of the action class that Struts calls to execute the action. The class name is fully qualified name.
    • Open the java file of the class (if it exists) and depending on the action (Action, DispatchAction, LookupDispatchAction), you will have to find its mappings and see what method Struts invokes.
    • In your example, my assumption will be based that your landing.do is of type Action. Therefore, read what the execute() method does. All actions actually, is execute() by Struts. The other actions are just Template Method patterns that knows what method to call by some mapping.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm just getting started with RoR (and web development in general). I know that
Just getting started using MVC in ASP.NET, I'm going to have it so users
I am just getting started with Silverlight and have recently added a Silverlight project
We just started a new ASP.Net project that uses web services to serialize some
I have a new web app that is packaged as a WAR as part
Just getting started with Linq to SQL so forgive the newbie question. I'm trying
I am just getting started with flex and am using the SDK (not Flex
I'm just getting started with learning about Unit testing (and TDD in general). My
I'm just getting started with Custom User Controls in C# and I'm wondering if
I'm just getting started working with foreign keys for the first time and I'm

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.