我有一个名为roundcube的文件夹,还有一个名为webmail.domain.org的子域名。我在.htaccess中添加此代码以阻止访问domain.org/roundcube,并仅允许在webmail.domain.org上使用。
RewriteEngine on
RewriteCond %{HTTP_HOST} !^webmail\.domain\.org$ [NC]
RewriteRule ^roundcube/$ http://webmail.domain.org [L,NC,R=301]`
访问domain.org/roundcube仍然有效,webmail.domain.org给了我这个错误:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, me@domain.org and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
我做错了什么?