嗨,我在我的服务器上有此文件夹,它是clients / nannyshareaustralia,我正在使用codeigniter框架,我也已经在基本URL中设置了config.php。即时通讯也为htaccess文件添加
RewriteEngine On
RewriteCond %{REQUEST_URI} ^system.*
RewriteCond $1 ^(index\.php|robots\.txt|favicon\.ico|images|js|assets|css)
RewriteRule ^(.*)$ /clients/nannyshareaustralia/index.php?/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /clients/nannyshareaustralia/index.php?/$1 [L]
当我在浏览器中运行它时
Forbidden
You don't have permission to access /clients/nannyshareaustralia on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
有人可以帮我解决这个问题吗?非常感谢任何帮助
RewriteEngine On
RewriteBase /clients/nannyshareaustralia
RewriteCond %{REQUEST_URI} ^system.*
RewriteCond $1 ^(index\.php|robots\.txt|favicon\.ico|images|js|assets|css)
....
RewriteBase
在您的.htaccess
授予中添加了mod_rewrite
在服务器上启用的规则。
note备注如果您以类似方式访问目录www.domain.com/clients/nannyshareaustralia
,则必须将RewriteBase添加到.htaccess
但是,如果将url / domain指向文件夹clients/nannyshareaustralia
,则不需要RewriteBase
。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句