我想重写一个URL,但我一直没有得到任何适当的结果。
I would like to rewrite an url, but I always do not get any adequate results.
我想网址 http://something.domain.com/index.php?arguments ... 实际访问 http://domain.com/index.php?username=something&arguments ......
I would like the url http://something.domain.com/index.php?arguments... to actually visit http://domain.com/index.php?username=something&arguments...
我曾尝试与做一个通配符项* .domain.com并使用互联网上的一些code,但毫无效果。
I have tried with making a wildcard entry *.domain.com and using some code on the internet, but nothing worked.
我不断收到一个默认网站页面 任何想法如何解决这个问题?
I keep getting a "Default Website Page" Any ideas how to solve this problem?
您可以在的东西域名:
You can use this code in your DOCUMENT_ROOT/.htaccess
file of something
domain:
RewriteEngine On
RewriteCond %{HTTP_HOST} ^([^.]+).(domain.com)$ [NC]
RewriteRule ^(index.php)$ http://%2/$1?username=%1 [L,QSA,NC,R]
上一篇:如何在laravel删除文件夹中的公共文件、夹中、如何在、laravel
下一篇:mod_rewrite的重写example.com/page.php?v1=abc&v2=def到example.com/abc/def~~V重写、com、page、mod_rewri