In a single install wordpress, not wp-ms
i m trying to do this subcategory to subdomain mapping, the subdomain structure is with country it would look like this:
thailand.maindomain.com
singapore.maindomain.com
maindomain.com
in maindomain.com i have category of each country respectively,
maindomain.com/singapore
and i would like to know is there a wayto make as below
maindomain.com/singapore --> singapore.maindomain.com
maindomain.com/thailand--> thailand.maindomain.com
You could possible set up a wildcard DNS record for *.maindomain.com and then use web server redirects or a WordPress hook to push the visitor onto maindomain.com/$1
thank you tcbarrett for the reply,
do the subdomain need to have content to display?
maindomain.com/singapore --> singapore.maindomain.com
b;cos i m trying to display content of
maindomain.com/singapore and the url rewrite show singapore.maindomain.com
digibucc
Member
Posted 1 year ago #
yeah most hosting companies have free subdomains, at least a number of them.
for example on one site i maintain they have a 'nascar.site.com' , that really just goes to 'site.com/nascar' so once you have it so that the subdomain points to the proper directory on the main domain - you can set up a url redirect via plugin/htaccess if necessary.
thanks digibucc, the subdomain.maindomain.com had A record pointed to the 2nd server, i m figuring it to show the content at maindomain.com/subdomain
arrentan
Member
Posted 1 year ago #
Gulf, why not you just import and and export your post based on category to your sub blog with WordPress multisite installation?
It will save up your time for the redirection and gives better SEO result.
that is an initial ideal but when comes to few 10s of them it is a nightmare to manage them.
and i m only needing a few like 3~4 OF them in subdomain the rest of the categories will be remain in subdirectory..
thanks