Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
嗨,我只想将 domain.com(不是 www.domain.com)重定向到子文件夹
我试过:
RewriteCond %{HTTP_HOST} ^?YourDomain.com$ RewriteRule ^(/)?$ page [L]
但它给出了内部服务器错误
500 internal server error 是由错误的表达式引起的:
# what's this? -----------v RewriteCond %{HTTP_HOST} ^?YourDomain.com$
不知道你想用那个问号做什么。但你可能想要这样的东西:
RewriteCond %{HTTP_HOST} ^YourDomain.com$ [NC]
这[NC]使它不区分大小写。
[NC]