This is a discussion on Interesting Trailing Slash Problem - Redefining Port Assignments within the Apache Web Server forums, part of the Web Server and Related Forums category; Here's my scenario. I have an Alteon AceDirector 2 webswitch that gets an IP allocated to it for a ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Here's my scenario. I have an Alteon AceDirector 2 webswitch that gets an IP allocated to it for a specific domain and only has ports 80 and 443 open. These ports get remapped to ports on a webfarm, for this instance, 50005 (non-SSL) and 60005 (SSL) ports for each box. If I call something like http://www.somedomain.com/webdir/, I can see the pages. If I call it without the trailing slash, the browser eventually gives up the request and returns an error. Telnetting into the IP representative for the domain and issuing a GET for /webdir yields this: GET /webdir <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <HTML><HEAD> <TITLE>301 Moved Permanently</TITLE> </HEAD><BODY> <H1>Moved Permanently</H1> The document has moved <A HREF="http://www.somedomain.com:50005/webdir/">here</A>.<P> <HR> <ADDRESS>Apache/1.3.27 Server at www.somedomain.com Port 50005</ADDRESS> </BODY></HTML> I COULD enable port mapping on my webswitch IP's for 50005 and 60005, however, I don't think this is a feasable idea. Can I use mod_rewrite to rewrite the SERVER_PORT back to their respective and standard ports? -- <html><body><form><input type crash></form></body></html> begin |
|
|||
|
WarpKat wrote:
> Here's my scenario. > > I have an Alteon AceDirector 2 webswitch that gets an IP allocated to it for > a specific domain and only has ports 80 and 443 open. These ports get > remapped to ports on a webfarm, for this instance, 50005 (non-SSL) and > 60005 (SSL) ports for each box. > > If I call something like http://www.somedomain.com/webdir/, I can see the > pages. > > If I call it without the trailing slash, the browser eventually gives up the > request and returns an error. > Its' the HTTP procol which wants this http://site/dir means give the file name dir otherwise http://site/dir means givvee me the contnt of the directory dir You mays use mod_rewrite to overcome this problem I don't remember the rule but you can look at the apache documentation for the mod_rerwrite at http://www.apache.org > Telnetting into the IP representative for the domain and issuing a GET for > /webdir yields this: > > GET /webdir > <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> > <HTML><HEAD> > <TITLE>301 Moved Permanently</TITLE> > </HEAD><BODY> > <H1>Moved Permanently</H1> > The document has moved <A > HREF="http://www.somedomain.com:50005/webdir/">here</A>.<P> > <HR> > <ADDRESS>Apache/1.3.27 Server at www.somedomain.com Port 50005</ADDRESS> > </BODY></HTML> > > I COULD enable port mapping on my webswitch IP's for 50005 and 60005, > however, I don't think this is a feasable idea. > > Can I use mod_rewrite to rewrite the SERVER_PORT back to their respective > and standard ports? yes as I told you above > |
| Thread Tools | |
| Display Modes | |
|
|