Hello,
I have created rewrite rule from cpanel but one url is working second giving me cpanel default apache page.
Web site abc.com is hosted on Cpanel server and xyz.com is external website.
1). Subdomain cp.abc.com successfully redirected to http://cp.xyz.com
RewriteEngine on
RewriteCond %{HTTP_HOST} ^cp.abc.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.cp.abc.com$
RewriteRule ^/?$ "http\:\/\/cp\.xyz\.com" [R=301,L]
2). Subdomain mail.abc.com should redirect to https://webmail.xyz.com but giving default apache page.
RewriteEngine on
RewriteCond %{HTTP_HOST} ^mail.abc.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.mail.abc.com$
RewriteRule ^/?$ "https\:\/\/webmail\.xyz\.com" [R=301,L]
I have also ensured IP and document root path on both subdomains under /var/cpanel/userdata/username/ directory and it is correct.
Thanks,
Imran Khan.
I have created rewrite rule from cpanel but one url is working second giving me cpanel default apache page.
Web site abc.com is hosted on Cpanel server and xyz.com is external website.
1). Subdomain cp.abc.com successfully redirected to http://cp.xyz.com
RewriteEngine on
RewriteCond %{HTTP_HOST} ^cp.abc.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.cp.abc.com$
RewriteRule ^/?$ "http\:\/\/cp\.xyz\.com" [R=301,L]
2). Subdomain mail.abc.com should redirect to https://webmail.xyz.com but giving default apache page.
RewriteEngine on
RewriteCond %{HTTP_HOST} ^mail.abc.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.mail.abc.com$
RewriteRule ^/?$ "https\:\/\/webmail\.xyz\.com" [R=301,L]
I have also ensured IP and document root path on both subdomains under /var/cpanel/userdata/username/ directory and it is correct.
Thanks,
Imran Khan.