07-29-2015, 10:33 AM
07-29-2015, 08:14 PM
easy...
Setup the domain. Then setup the subdomain on same folder.
Create a .htaccess that will enforce the subdomain as main URL.
M B
Setup the domain. Then setup the subdomain on same folder.
Create a .htaccess that will enforce the subdomain as main URL.
M B
07-30-2015, 05:29 AM
Don't know if you've already sorted this but there different ways to redirect your URL to a subdomain check out this link. http://blogs.tanertemel.co.uk/2015/05/se...irect.html
08-08-2015, 01:38 AM
(07-29-2015, 08:14 PM)Me.B Wrote: [ -> ]easy...
Setup the domain. Then setup the subdomain on same folder.
Create a .htaccess that will enforce the subdomain as main URL.
M B
What about if I have to setup a subdomain first?
Thanks!
08-08-2015, 02:37 AM
Why would you need to setup the subdomain first?
08-08-2015, 12:34 PM
(08-08-2015, 02:37 AM)apinto Wrote: [ -> ]Why would you need to setup the subdomain first?
Thanks for your reply, but I think you must be misunderstanding, please read my question properly: domain (xyz.com) point to a subdomain (xyz.abc.com).
The subdomain is under domain of abc.com, whereas domain is a different one (xyz.com).
08-08-2015, 09:17 PM
It's very easy to do that.
First you add abc.coom domain (or add it as a shared domain that will allow abc.com to be used by all accounts to create subdomains).
Than you create the subdomain xyz.abc.com
On the public_html folder of that subdomain you create a htaccess file that redirects ot the domain you want.
You can use http://www.htaccessredirect.net/ to generate your file fi you are not sure about how it is done.
The above steps are true, either for a subdomain or a regular top level domain (abc.com)
Also, if you need to create the subdomain first, it will work exactly the same way, however it will be redirected to a error page (because domain does not exist)
First you add abc.coom domain (or add it as a shared domain that will allow abc.com to be used by all accounts to create subdomains).
Than you create the subdomain xyz.abc.com
On the public_html folder of that subdomain you create a htaccess file that redirects ot the domain you want.
You can use http://www.htaccessredirect.net/ to generate your file fi you are not sure about how it is done.
The above steps are true, either for a subdomain or a regular top level domain (abc.com)
Also, if you need to create the subdomain first, it will work exactly the same way, however it will be redirected to a error page (because domain does not exist)
08-11-2015, 06:41 PM
Thanks, apinto! But if I use htaccess for the redirection, will the URL on my browser changed to destination domain name (in my case, xyz.abc.com)?
And when I click on the link at xyz.abc.com after htaccess redirection, for example contactus.php page, is it showing http://xyz.abc.com/contactus.php or http://xyz.com/contactus.php?
And when I click on the link at xyz.abc.com after htaccess redirection, for example contactus.php page, is it showing http://xyz.abc.com/contactus.php or http://xyz.com/contactus.php?
08-11-2015, 07:21 PM
(08-11-2015, 06:41 PM)tonywonghs Wrote: [ -> ]Thanks, apinto! But if I use htaccess for the redirection, will the URL on my browser changed to destination domain name (in my case, xyz.abc.com)?
And when I click on the link at xyz.abc.com after htaccess redirection, for example contactus.php page, is it showing http://xyz.abc.com/contactus.php or http://xyz.com/contactus.php?
This is something you should try and see the results...
However the URL on the address bar will the destination one.
The URL will always be the destination one unless you specify otherwise.