What?

I'm sorry, but I'm not asking about how to assemble an URL.

I want to retrieve the original URL sent by the browser in the request. The request.getRequestURL() is wrapped and modified with each forward, and I want the first, by the browser, requested URL.

Since so many seem to misunderstand me:
1. User inputs "http://localhost/appname/input.do"; in browser. (Mapped to InputAction) 2. InputAction's request.getRequestURL() is "http://localhost/appname/input.do";
3. InputAction forward to OtherAction.
4. The OtherAction's request.getRequestURL() is "http://localhost/appname/other.do";. <-- THIS ISN'T WHAT I WANT.

I want to retrieve the URL "http://localhost/appname/input.do"; in the OtherAction WITHOUT modifying InputAction. How do I do this?

Rimzim Sinha skrev:
Try
   getContextPAth + gathRequestURL...

Martin Gainty <[EMAIL PROTECTED]> wrote:
  
http://www.docjar.com/docs/api/org/apache/struts/action/Action.html#execute(org.apache.struts.action.ActionMapping,%20org.apache.struts.action.ActionForm,%20javax.servlet.http.HttpServletRequest,%20javax.servlet.http.HttpServletResponse)
The second parameter of the Action execute method is 'ActionForm'
HTH,
Martin-
*********************************************************************
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed. If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy. Thank you.



----- Original Message ----- From: "David Grundberg" To: "Struts Users Mailing List" Sent: Sunday, September 10, 2006 8:46 AM
Subject: How do I get the original RequestURI?


Hi,

I want to do something like this:
1. User enters http://localhost/appname/welcome.do
2. PlaceAction forwards to list.do
3. In ListAction, I want to retrieve the URL the user entered "/appname/welcome.do".

The problem: when I run getRequestURI in the ListAction, all I get is "/appname/list.do". I guess this is a sort of natural thing for it to do, but how do I get the original URI? (/appname/welcome.do)

Any help appreciated!

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



                
---------------------------------
Why keep checking for Mail? The all-new Yahoo! Mail shows you when there are 
new messages.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to