Redirection of htaccess Only on Main Domain Not on Addon Domain

JunJoo

Registered
Mar 2, 2019
1
0
1
India
cPanel Access Level
Website Owner
Hi!

I googled a lot but couldn't find solution to my problem. My problem is I have many redirections on my primary domain.

Like say for http to https , to remove page extension. for error document. to remove trailing slash etc...

But now I have a addon domain and all the redirection is working on that aswell. Plus my addon domain is ending with a url like

maindomain.com/addondomain.com

That's what am getting if I place any htaccess redirection on my primary domain. I want to remove my addon domain from my redirection.

I tried many rules but most of the time result is same or am getting 403 error page.

Please help me to resolve this issue.

Thanks
 

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
8,012
648
263
Houston
cPanel Access Level
DataCenter Provider
Hello @JunJoo

When you access your addon domain using the actual addon domain not the added subdomain or maindomain.com/addondomain.com what happens?

How are you adding the redirects, are you using the UI and specifying that it's just for the primary domain when you're adding them? Do you have an example of a redirect rule you've added that is being imposed on the addon domain? (just be sure to remove any identifying information before adding here)


Thanks!