Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Jan 2006
    Location
    Mulund, India, India
    Posts
    118

    Default URL redirection without changing the address in the address bar

    Hello,

    I want to redirect a website to a particular URL so that the address bar shows the same URL and not the destination URL. I know it is possible via URL masking, however, I want it in such a way that whenever somebody clicks on any link in the website, the address bar should still show the original URL. To put it in simple words,

    Suppose I want to redirect http://www.xyz.com to http://www.abc.com/pqr/index.htm. Now if there is a link named contact/index.htm and somebody clicks on it the address bar should display http://www.xyz.com/contact/index.htm and not redirect to http://www.abc.com/pqr/contact/index.htm.

    How can it be possible using URL Rewrite method in .htaccess file? Can anybody guide me?
    Nitesh Shah

    Cheap Managed Dedicated Servers - http://www.qualispace.com/managed-servers/index.html

  2. #2
    Technical Product Specialist cPanelDavidG's Avatar
    Join Date
    Nov 2006
    Location
    Houston, TX
    Posts
    11,189
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Quote Originally Posted by nitaish View Post
    Hello,

    I want to redirect a website to a particular URL so that the address bar shows the same URL and not the destination URL. I know it is possible via URL masking, however, I want it in such a way that whenever somebody clicks on any link in the website, the address bar should still show the original URL. To put it in simple words,

    Suppose I want to redirect http://www.xyz.com to http://www.abc.com/pqr/index.htm. Now if there is a link named contact/index.htm and somebody clicks on it the address bar should display http://www.xyz.com/contact/index.htm and not redirect to http://www.abc.com/pqr/contact/index.htm.

    How can it be possible using URL Rewrite method in .htaccess file? Can anybody guide me?
    That sounds a lot like using parked domains. However, mod_rewrite is also a very useful tool for situations like this. I usually consult the Apache documentation for mod_rewrite for help with using mod_rewrite.

    Apache 1.3 mod_rewrite docs:
    http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html

    Apache 2.0 mod_rewrite docs:
    http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html

    Apache 2.2 mod_rewrite docs:
    http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html

  3. #3
    Member
    Join Date
    Jan 2006
    Location
    Mulund, India, India
    Posts
    118

    Default

    do you have a working example for this?
    Nitesh Shah

    Cheap Managed Dedicated Servers - http://www.qualispace.com/managed-servers/index.html

Similar Threads & Tags
Similar threads

  1. Address bar immobilizer
    By martusi in forum New User Questions
    Replies: 4
    Last Post: 08-04-2009, 06:06 AM
  2. Address bar immobilizer
    By martusi in forum cPanel Developers
    Replies: 0
    Last Post: 07-27-2009, 05:37 AM
  3. IP address shows in address bar, not the domain name question
    By addam in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 09-26-2008, 12:27 PM
  4. Sub-Domain forwarder without changing address bar at top?
    By noimad1 in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 10-13-2005, 05:44 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube