Hmm.. ok maybe I'm confused here on the terminology of what you are saying. So:
1) is all of www.mydomain.com/app running on port 8060, or ONLY the app/submitComplete.do ? I'm _guessing_ the whole thing is on one port. 2) Are you actually doing a redirect to the browser OR are you doing a forward from one action to the other? Meaning, could your formSubmit.do Action perform a forward to the other action, submitComplete.do. Now, IF this is what you are doing (a forward and not a redirect), then I see what you are asking as the server (Struts) is doing a forward and the browser is showing the resulting page's URL, which you don't want. In that case I'm not sure how it is done :-) Unless you have the 'redirect' attribute set to 'true' in the forward tag, in which case the browser is going to show the URL like mentioned before. If I'm way off on these then I apologize :-) Robert -----Original Message----- From: Bill Clinton [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 26, 2002 1:43 PM To: Struts Users Mailing List Subject: Re: How can I get rid of the port on redirects. Thanks for your answer Robert, but perhaps I am not being descriptive enough. I have an action called formSubmit. It would look to the user like: http://www.mydomain.com/app/formSubmit.do when they hit the submit button on the form. If this action is successful, I would like to redirect to an action called submitComplete. This should look to the user like: http://www.mydomain.com/app/submitComplete.do but instead, it attempts to send my user to: http://www.mydomain.com:8060/app/submitComplete.do which is incorrect. I assume the internals of struts are using the getServerName() and getServerPort() methods to form this URL. My only question is where? I have seen other examples in the struts source where there are work arounds for port 80 and the https port (443). You can look at these workarounds in the org.apache.struts.util.RequestUtils class. I am looking for a smiliar workaround where i can avoid having struts append the port to the URL when I redirect. Bill Robert wrote: >You could probably do that, but if you take out the port BEFORE doing >the redirect, then the browser won't have the correct port and you would >end up with a 404 error, no? > >Remember that in a redirect, the server tells the browser where to go, >and thus it has to supply the correct URL including the port. In a >forward, all the action takes place on the server, so the browser >doesn't really know that a forward took place. > >If I'm wrong here, someone let me know! > >- Robert > >-----Original Message----- >From: Bill Clinton [mailto:[EMAIL PROTECTED]] >Sent: Tuesday, February 26, 2002 1:23 PM >To: Struts Users Mailing List >Subject: Re: How can I get rid of the port on redirects. > >But, isn't there a spot to intercept it and screen out the port before >it is handed off to the browser? Struts has to be forming that URL >somewhere, I just can't find it. > >Robert wrote: > >>If it's a redirect, I don't think you can, since the redirect URL is >>given to the browser, as opposed to a forward. Maybe you can with >>frames, but frames isn't exactly an 'elegant' solution. >> >>- Robert >> >>-----Original Message----- >>From: Bill Clinton [mailto:[EMAIL PROTECTED]] >>Sent: Tuesday, February 26, 2002 1:03 PM >>To: Struts Users Mailing List >>Subject: How can I get rid of the port on redirects. >> >>Hello, >> >>I am running on port 8060, but the outside world sees my my application >> > >>through a proxy run on port 80. When I set a forward to an action and >>use the redirect=true flag, the port "8060" gets tagged on to the >>redirect and it times out since this port is not open on the proxy. I >>am trying to look for somewhere in the struts source code where I can >>strip out the refernce to this port on redirects. Can someone please >>show me where I would need to modify the source? I am unable to find >>it. >> >>Bill >> >> >>-- >>To unsubscribe, e-mail: >><mailto:[EMAIL PROTECTED]> >>For additional commands, e-mail: >><mailto:[EMAIL PROTECTED]> >> >> >> >>-- >>To unsubscribe, e-mail: >> ><mailto:[EMAIL PROTECTED]> > >>For additional commands, e-mail: >> ><mailto:[EMAIL PROTECTED]> > >> >>. >> > > > >-- >To unsubscribe, e-mail: ><mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: ><mailto:[EMAIL PROTECTED]> > > > >-- >To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> > > >. > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>