Hello. I'm a problem and i'm really going mad with redirect...
All i want to do is very simple.
I've an action that sends a post to a server. The server answer with a page to
which i've to redirect the client.
When the server answer, i read the page in a buffer and i extract the url to
which i've to redirect.

Then i use:

        reponse.sendRedirect(redirectURL);

but the thing does not work. If the url is "https://page.jsp?param=something";
and my current namespace is web/hello/ then i got an error like:

 The requested resource (/web/hello/PE%20HTML%20PUBLIC) is not available.

If i copy and paste the url like this:


      reponse.sendRedirect("https://page.jsp?param=something";);
      return null; //return null to struts

the browser is correctly redirected. Now..the redirectURL variable contains
exactly the same url, but it does work only if i copy and paste the url like a
constant value... It's really weird, isn't it?
The same happens if I don't implement ServletResponseAware.In fact i tried even
with:

         <result name="success" type="redirect">
                                <param name="location">
                                        ${redirectURL}
                                </param>
        </result> 

in struts.xml, where redirect url was a field in my action class that was filled
in with the url i got from the post to the third party server.
It's really so strange to do a redirect to an url inside an action?

Thank you!




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

Reply via email to