Making additional domains work in Joomla on Pair Networks

How to add an additional domain to a Joomla installation hosted at Pair Networks to point to a particular subportion of that site.

Imagine a Joomla installation hosted at Pair Networks with the domain You want a new domain,, to point to a particular section or page on that Joomla installation. (Let us set aside the pedantic fact that pages per se don’t exist in Joomla; you know what I mean.)

It is assumed that you own the domain and that your domain registrar is using Pair’s nameservers for it. It is also assumed that everything that might affect or rewrite the URLs in Apache or Joomla are set as desired and will not be changed later (because otherwise you will break URL pointing). Examples of things that affect or rewrite URLs are Joomla’s SEO settings (Global Configuration – Site – SEO Settings), SEO extensions, and multilingual extensions like Joomfish. Set such things however you like but don’t go changing them later.

Determine the current URL of the section or page you want to point to, for example In this example the URL is language-specific; ideally you would determine a working language-agnostic URL, such as for example

Enter the URL directly into a browser and confirm that it displays as intended. If the page or section does not display with the intended template, specify the template in the URL and try again.

Decide upon (but do not create) an appropriate subdirectory in the Joomla docroot to serve as a landing for the additional domain. Following our example, foobar/.

Add as a new shared domain on your hosting account. In the Pair Account Control Center (ACC), go to Domain Hosting Management – Add – Add a Domain Name That is Already Registered. Enter the new domain, select the shared IP option, and click “Proceed”. Select “Mapped to a subdirectory of your hosting account” and provide the path to the additional domain’s landing subdirectory, e.g. /usr/www/users/USERNAME/foobar/. The ACC creates that directory.

Place in the newly created directory a file named .htaccess, containing rewrite rules of the form:

RewriteEngine on

RewriteCond %{HTTP_HOST} ^$ [OR]
RewriteCond %{HTTP_HOST} ^$
RewriteRule ^(.*)$ "" [R=301,L]

Modify the rules as needed.

TODO: Figure out how to get the browser to display, not, in the URL. This may be a job for simple redirection or virtual hosting instead of mod_rewrite.


About Warren Post

So far: Customer support guy, jungle guide, IT consultant, beach bum, entrepreneur, teacher, diplomat, over-enthusiastic cyclist. Tomorrow: who knows?
This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s