AddOn domain redirects to subdomain

radu.costinean

Registered
May 19, 2014
3
0
1
cPanel Access Level
Root Administrator
Hi there,
I have my own VPS, I installed cPanel-WHM and I created my first cPanel account in WHM to manage my domains.
When I created it, I assigned to it the domain website.com. After few days, which is today, I added another domain something.com which has the folder under /home/account-name/public_html/something.com.
The problem is that adding something.com as an addon domain in cPanel, it created a subdomain for website.com too.
Example: something.website.com
So when I first opened in my broweser something.com, it redirected me to website.com/something.com

However I managed to do a redirect of the subdomain something.website.com to something.com. But I don't think that's the proper way it works :)

So how can i fix this issue, that whenever I add a new addon domain, it won't create a subdomain but a domain.

Thanks :)
Radu

- - - Updated - - -

Btw I have created an wildcard for website.com to install Wordpress Multisite. I created this wildcard *.website.com as a subdomain
 

radu.costinean

Registered
May 19, 2014
3
0
1
cPanel Access Level
Root Administrator
That's strange because I have other domain hosted with a company (shared hosting) and they provide cPanel account. When I added a second addon domain, it created the subdomain, but it was pointing to "something.com" (where something.com is the second domain). Instead now when I went to http://something.com it was redirecting me to http://website.com/something.com/ which is strange :)
Anyway, thanks for clarifying it :)
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,912
2,241
363
It seems like you might have a script installed that redirects the domain name to the URL you see in the address bar, or you have custom Mod_Rewrite rules added within the account's .htaccess file in the public_html directory that are redirecting the domain name. Please check to see if either of those two scenarios apply here.

Thank you.
 

radu.costinean

Registered
May 19, 2014
3
0
1
cPanel Access Level
Root Administrator
I suppose you are right, because it might be the htaccess rules I added for Wordpress MU. I am not an htaccess expert and I can't confirm it, but that might be the cause because I don't have other script installed on that server.
Thanks :) You can mark this thread as solved.

Regards,
Radu