As a personal comment, be aware that domain cloaking/masking adds potential bottlenecks and additional points of failure for the site. If the source/destination domain you're trying to cloak are on the same cPanel account, you're best served by setting up the additional domain as an "Addon Domain" with the same documentroot. This way you're not adding in an unnecessary proxy aspect.
Without cloaking, the connection is always a direct connection to the involved site.
Client -> Site A
*redirect*
Client -> Site B
With cloaking, you're adding that bottleneck into the equation.
Client -> Site A -> Site B
You're now reliant upon Site A acting as a proxy and at the mercy of its performance. This isn't an issue if it's on the same server. But, if it's on the same server why not just use an Addon Domain with identical docroots and skip the unnecessary proxy (cloak)?
However, even still I believe search engines punish your rankings in both situations (which cloaking or setting addon domains to identical roots would portray) because you'd be producing duplicate content in their eyes.
Using a 301/302 redirect, like the article states, explicitly tells the search engine it's a redirect and not a duplicate and therefore doesn't hurt rankings. Cloaking/masking makes an entire site appear as duplicate content and hurts rankings.
So, from a performance aspect *and* search ranking aspect I do not see the benefit to masking/cloaking. Just be aware of what masking/cloaking is and what it means to the site.
Nonetheless! This is already possible with cPanel servers as long as you have mod_proxy compiled in with Apache (this is usually the case since cPanel's proxy subdomains require mod_proxy).
*** To deploy such masking/cloaking, simply replace the R=301 or R=302 argument in your .htaccess redirect with P (meaning 'Proxy').
Example:
RewriteRule (.*) http://www.google.com/$1 [P]
The above would cloak (proxy) all traffic to google.com
It's that simple.
- 1 Users Found This Useful