ipel
ipel

Reputation: 1348

how to redirect all the domain extensions on the main site domain

I have many domains with different extensions, for example: website.com, website.net, website.org,...

the main site/domain is website.com where I have installed WORDPRESS

what I'm tring to do is to set all the others domain (website.net, website.org,..) to point on the main site/domain (website.com)

so, for example, if I go on "website.net" or "website.net/something" should I be redirect on website.com

I have cpanel so i guess that the first way is to add all the domains with the "addon domains" function, and then add in the wp-config.php:

define( 'NOBLOGREDIRECT', 'http://website.com' );

or another soluzion could probably be to simply park all the domains with cpanel function, or se the htaccess, but how?

what is the best solution in this case?

PS: the main website is in a subfolder (not root)

Upvotes: 0

Views: 1463

Answers (1)

Panama Jack
Panama Jack

Reputation: 24468

Just do a DNS forward and be done with it. Go to your DNS provider and just setup domain forwarding to your main domain name.

Forward website.net and website.org to website.com. When anyone goes to website.net it will redirect to website.com and same with .org. The domains will need to be parked.

If you host your DNS at a registrar like GoDaddy, then this will show you how.

http://support.godaddy.com/help/article/422/forwarding-or-masking-your-domain-name

Otherwise, the procedure is the same wherever your DNS is hosted. I suggest forwarding it without masking.

Upvotes: 1

Related Questions