0

I have registered 3 domains with .com, .co.in and .in extensions. My .com domain is hosted. I want users to be redirected to the .com website when they type in the .co.in and .in urls. How do I do that?

  • In your web server configuration. – Ignacio Vazquez-Abrams Apr 19 '11 at 09:15
  • which webserver are you using? – Marco Ramos Apr 19 '11 at 09:28
  • 1
    possible duplicate of [Everything You Ever Wanted to Know about Mod_Rewrite Rules but Were Afraid to Ask?](http://serverfault.com/questions/214512/everything-you-ever-wanted-to-know-about-mod-rewrite-rules-but-were-afraid-to-ask) – coredump Apr 19 '11 at 09:41
  • I am a noob in this area. So please make your responses as simple as possible. @Ignacio I am using cpanel, how do I do it from there? @Marco, the site is hosted by a web hosting company. They are running a linux server, I don't know what http server they run. – Ragunath Jawahar Apr 19 '11 at 10:00

2 Answers2

1

There are 2 Solutions for this problem

Solution 1:

CNAME Record on the DNS-Server.

IN CNAME example.com.

This DNS Record Redirect the domain e.g. example.io to example.com. If you wan't to redirect a Subdomain e.g. sub.example.io you need to use:

sub IN CNAME example.com.

Solution 2:

Redirect with the Webserver

NGINX:

server {
    listen 80;
    server_name example.io;
    return 301 http://example.com$request_uri;
}

Apache:

<VirtualHost *:80>
    ServerName example.io
    Redirect 301 / http://example.com
</VirtualHost>

Apache may need to be changed.

Spirit
  • 224
  • 1
  • 4
0
  1. Log into cpanel
  2. Click 'Parked Domains'
  3. Add the domains
  4. Go back to 'Parked Domains'
  5. Then for each domain:
    1. Click Manage Redirection
    2. Enter the address you want the domain to rediect (such as www.example.com)
    3. Click save

Remember: your .co.in and .in domains have to be setup to 'point' to your cpanel webhost for this to work (the domain's nameservers set to your cpanel host). You also need to have 2 (or more) 'Parked Domains' available on your cpanel package.

syserr0r
  • 500
  • 3
  • 10