: I run my own server on a similar principle, this is my configuration: It should work with little modification for you assuming that GoDaddy supports this type of thing (it seems to from your
I run my own server on a similar principle, this is my configuration:
It should work with little modification for you assuming that GoDaddy supports this type of thing (it seems to from your question), except you'll need to change paths obviously. This configuration rewrites into folders like /var/www/vhosts/example.com/www for example.com.
RewriteEngine on
# Directory listing icons!
RewriteRule ^/icons/(.*)$ /var/www/icons/ [L]
# Ensure there is no RewriteCond %{HTTP_HOST} ^www.(.*)$ [NC]
RewriteRule ^(.*)$ %1 [R,L]
# Special case for the base domain
RewriteCond %{HTTP_HOST} ^(localhost|[^.]+.[^.]{1,8}(.au)?)$ [NC]
RewriteRule ^(.*)$ /var/www/vhosts/%1/www
# Rewrite subdomains into subdirectories
RewriteCond %{HTTP_HOST} ^(.*?).(localhost|[^.]+.[^.]{1,8}(.au)?)$ [NC]
RewriteRule ^(.*)$ /var/www/vhosts/%2/%1
More posts by @Debbie626
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.