This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
ISAPI_Rewrite 2.x (Forum Locked Forum Locked)
 Helicon Tech : ISAPI_Rewrite 2.x
Subject Topic: redirect to other port / server
Author
Message |
ebijs
Newbie


Joined: 21 November 2004
Location: Netherlands
Posts: 22
Posted: 21 January 2011 at 4:50am

Hi,

i need to redirect:

http://server.com:9000/some_stuff_here        and
http://www.server.com:9000/some_stuff_here

to http://sub.server.com:9000/some_stuff_here

Any ideas?
Back to Top
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 21 January 2011 at 7:08am

You can do it with the following config:

[ISAPI_Rewrite]
RewriteCond Host: (?:www\.)?server\.com\:9000
RewriteRule (.*) http\://sub.server.com\:9000$1 [I,RP]

__________________
Regards,
Anton
Back to Top
 
ebijs
Newbie


Joined: 21 November 2004
Location: Netherlands
Posts: 22
Posted: 21 January 2011 at 8:54am

Thank you Anton.
I need also a version who catch all subdomains.

Something like this:

http://any_sub_domain.server.com:9000/some_stuff_here       
and
http://www.any_sub_domain.server.com:9000/some_stuff_here

Back to Top
 
ebijs
Newbie


Joined: 21 November 2004
Location: Netherlands
Posts: 22
Posted: 23 January 2011 at 1:21am

Anton, can you help me out?
Back to Top
 
Anton
Admin Group


Joined: 30 January 2007
Location: Ukraine
Posts: 10519
Posted: 24 January 2011 at 3:24am

You mean you need to redirect everything to http://sub.server.com:9000?
Then it's like this:

[ISAPI_Rewrite]
RewriteCond Host: (?!sub\.)(.*)server\.com\:9000
RewriteRule (.*) http\://sub.server.com\:9000$1 [I,RP]

__________________
Regards,
Anton
Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum