Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
ISAPI_Rewrite 2.x support forum
 Helicon Tech : ISAPI_Rewrite 2.x support forum
Subject Topic: Rewrite without redirect Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
wromee
Newbie
Newbie


Joined: 05 June 2008
Location: Australia
Online Status: Offline
Posts: 1
Posted: 05 June 2008 at 7:45pm | IP Logged Quote wromee

url requested by a user is www.abc.com, I want to rewrite it to www.xyz.com while I show him the pages from www.abc.com. Is this possible in first place? Please kindly let me know, if yes, how and if no, why?
(FYI, I'm using ISAPI_Rewrite 2)

Back to Top View wromee's Profile Search for other posts by wromee
 
Anton
Moderator Group
Moderator Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 4695
Posted: 09 June 2008 at 8:31am | IP Logged Quote Anton

RewriteCond Host: www\.abc\.com
RewriteProxy (.+) http\://www.xyz.com$1 [I,U]

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
wilk
Newbie
Newbie


Joined: 11 July 2008
Location: United States
Online Status: Offline
Posts: 1
Posted: 11 July 2008 at 4:53pm | IP Logged Quote wilk

Re-mapping the url is relatively simple.  The problem is with application management.

If you map www.abc.com to its actual virtual directory application location of www.xyz.com/abc, is the application served from www.xyz.com or www.xyz.com/abc?

Using an HttpModule for a redirect works fine, but the user is shown the new url www.xyz.com/abc. Using Http Rewrite seems to remap the url o.k. and shows the user www.abc.com, but the application is served from www.xyz.com and it treats /abc as a subdirectory rather than an application.

With ISAPI Rewrite (as an ISAPI filter), will the application be served from the virtual directory application while the user (and search engine) still sees the www.abc.com url facade?

I know you have a try-before-you-buy policy, but I would need to change my hosting facility before I try.  I would like to know if this problem can be solved with ISAPI Rewrite.

Can anyone offer advice?

 



__________________
The obvious is really obvious once you see it.
Back to Top View wilk's Profile Search for other posts by wilk Visit wilk's Homepage
 
Lexey
Moderator Group
Moderator Group


Joined: 15 August 2002
Location: Russian Federation
Online Status: Offline
Posts: 7559
Posted: 12 July 2008 at 12:14pm | IP Logged Quote Lexey

It will be served in the /abc application. But note, if you are using IIS6 and /abc application is running in a application pool different from the root application pool then rewriting will not work.
Back to Top View Lexey's Profile Search for other posts by Lexey
 
acauchi
Newbie
Newbie


Joined: 30 July 2008
Online Status: Offline
Posts: 2
Posted: 30 July 2008 at 2:07am | IP Logged Quote acauchi

I am also a newbie on this subject and am trying to understand what wromee wants to do as I think I have a similar issue.

In my case I have a local site with specific folder and I want users to be redirected to another website on my local server. The steps I did and script I wrote is as follows:

first after opening the Helicon Manager I clicked on the specific site folder under the IIS Web Sites (Folder Named Intranet). Then I edited the .htaccess file in it and wrote the following

RewriteCond Host: http://localhost/intranet/cpg

RewriteProxy (.+) http://localhost/ific$1 [I,U]

I want users who type http:

RewriteCond Host: http://localhost/intranet/cpg to be redirected to http://localhost/ific

Still when I refreshed httP//localhost/intranet/cpg nothing happened. Can someone assist me? As explained am not familiar with coding

regards

acauchi

Back to Top View acauchi's Profile Search for other posts by acauchi
 
Lexey
Moderator Group
Moderator Group


Joined: 15 August 2002
Location: Russian Federation
Online Status: Offline
Posts: 7559
Posted: 31 July 2008 at 4:16pm | IP Logged Quote Lexey

RewriteCond Host: localhost
RewriteRule /intranet/cpg http\://localhost/intranet/cpg/ [I,RP]

RewriteCond Host: localhost
RewriteProxy /intranet/cpg(/.+) http\://localhost/ific$1 [I,U]
Back to Top View Lexey's Profile Search for other posts by Lexey
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
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