-
☆ A M B ☆
- 756 Posts
Well, what is the purpose of the sub-domain over using the folder architecture? What's your expected or desired management of content of the primary domain vs. the sub-domain?
In the past I've done this using rewrite rules to point the sub-domain to corresponding (same) aliased folder structure in Evo.
Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
Visit
CharlesMx.com for latest news and status updates.
discuss.answer
Hi CharlesMx.
Their SEO folks want a subdomain instead of a folder for a new section of the site.
Yes, if I can use .htaccess to rewrite the subdomain to a folder I'm golden. However, I'm pretty bad at regex. An example of what worked for you would be awesome.
Thanks.
-
☆ A M B ☆
- 756 Posts
This rule should match the sub-domain to the first level folder and also append the rest of the original URL after giving a complete URL.
If the user puts:
http://members.your-domain.com/list.html
would rewrite to:
http://your-domain.com/members/list.html
RewriteCond %{HTTP_HOST} ([^.]+)\.your-domain.com(.*) [NC]
RewriteRule %1%2
Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
Visit
CharlesMx.com for latest news and status updates.