Welcome to WebmasterWorld Guest from 188.8.131.52 , register , free tools , login , search , subscribe , help , library , announcements , recent posts , open posts Subscribe to WebmasterWorld
Wildcard DNS, Subdomain and mod rewrite rewrite any.site.com -> /root-of-site/test.php?subdomain=any iProgram msg:3104299 2:27 pm on Oct 1, 2006 (gmt 0) My DNS setting looks like this:
site.com A: 184.108.40.206
www. A: 220.127.116.11 *. A: 18.104.22.168
site.com is IP based site. Both www.site.com and anything.site.com point to same IP (22.214.171.124). There are /index.html and /test.php under root folder of site.com.
1. site.com 301 redirect to www.site.com, and
2. www.site.com shows /index.html and 3. others.site.com shows /test.php?subdomain=others 4. others.site.com/file1/file2.html shows /file.php?subdomain=others¶m1=file1¶m2=file2
How to create the /.htaccess file?
edited by: iProgram at 2:30 pm (utc) on Oct. 1, 2006]
jdMorgan msg:3109870 5:32 pm on Oct 5, 2006 (gmt 0)
Because of potentially high demand and relativley few contributors, we cannot write your code for you> But we will be glad to help you get it working -- Please see our forum charter.
To get started, see the documents cited in our
forum charter [ webmasterworld.com] and the tutorials in the Apache forum section of the WebmasterWorld library [ webmasterworld.com].
There are also many past threads on this subject, and a search on WebmasterWorld for "subdomain sudirectory rewritecond http_host rewriterule" should reduce the number of search results to help turn them up.