Need help with creating subdomain

femifitx

Member
Messages
114
Reaction score
1
Points
18
Hello all,

I would appreciate some guidance please. I have a custom domain (e.g. "abc.com") linked to my x10 subdomain. When people navigate to abc.com, they are taken to my x10 subdomain and can navigate to all subdirectories, but x10 never shows in the URL. Everything works perfectly.

Now, I want to add a subdomain to my custom domain (so, something like "sub.abc.com") and I want that to simply redirect to a page in my abc.com website e.g. when a person types in the URL sub.abc.com, they are taken to abc.com/newpage. How do I go about this? I created a subdomain in x10, but I'm not sure how to link that to my main domain and to the page. I suspect I will need to specify a redirection somewhere, but not sure where or how.

Any help would be appreciated.

Thanks!
 

femifitx

Member
Messages
114
Reaction score
1
Points
18
Nobody can provide any guidance with this? Since we moved from cPanel to Direct Admin, this has not been an intuitive process anymore, so any guidance from the Admins or any knowledgeable person(s) would be appreciated.

My custom domain was parked when we used cPanel and then referenced as a pointer when we were migrated to DA. How do I create a subdomain to my custom domain that redirects to a page?
 

spacresx

Community Advocate
Community Support
Messages
1,356
Reaction score
102
Points
63
if i understand correctly, what your trying to do is like abc.com but have that open abc.com/newfolder instead.
as i dont think you can do it as abc.com/new folder and open abc.com

when you add a folder to your public_html, that folder can become a subdomain of your main website.
simply by using for example abc.com/newfolder in your URL
it gets tricky if you want "newfolder" to open abc.com because abc.com is actually your public_html folder..
you would need something like a web-forwarding url (not provided by x10hosting i dont think)

note: you would need a index page like index.php index.html file etc. to get "newfolder" to open in a url.
you can also include a .htaccess file as well to the "newfolder",
basically copying the file structure as your public_html

maybe someone else can give you other ideas to
 

femifitx

Member
Messages
114
Reaction score
1
Points
18
@spacresx thanks for responding.

Not quite. Let me explain a bit better.

- My x10 (sub)domain is 123.x10host.com

- My custom domain is abc.com

- Currently, in my DirectAdmin, 123.x10host.com is set as a pointer to abc.com

- If I type in abc.com, it pulls up my website and appropriately shows the URL as abc.com (even though it's hosted at 123.x10host.com)

- Now, what I want to do is create a subdomain on my custom domain e.g. xyz.abc.com

- When I create a subdomain in x10 right now, it gives me xyz.123.x10host.com and I notice that a folder (123) is created under my public_html directory

- That folder contains an html.index file and a cgi-bin folder

- I have a page created already on my wordpress site - abc.com/page

- I now want to redirect traffic such that when one navigates to xyz.abc.com, they are taken to that page abc.com/page

Hope that makes my ask clearer.
 

spacresx

Community Advocate
Community Support
Messages
1,356
Reaction score
102
Points
63
ok your abc.com is actually your public_html folder,
so any folders added to public_html now technically become usable as a subdomain.
like in your example of abc.com/page would need a folder called 'page' to work.
you cannot normally make "abc.com/123" open the "abc.com/folder"
unless you use a web forward service like free dns
 

femifitx

Member
Messages
114
Reaction score
1
Points
18
Thanks @spacresx. Actually got one of the Moderators to help earlier. I'd gotten myself into a loop trying to add my custom domain separately (it was previously referenced as a pointer). Once they helped me sort that out, I created the subdomain and set a redirect logic in the landing file to the page I want. All now works fine.

Thanks so much for your kind attention.
 
Top