Я использую apache2 в ubuntu m/c. Я включил mod_rewrite и изменил Allowoveride All в apache2.confhtaccess Rewrite Правило не работает без index.php в url
Теперь я пытаюсь установить приложение Bug-Genie на свой сервер Но следующие правила .htaccess не работают как исключенные.
я могу получить доступ к:
http://localhost/roxsoft/thebuggenie-3.2.6/thebuggenie/**index.php**/wiki
Но я не могу доступа: --404 ошибка
http://localhost/roxsoft/thebuggenie-3.2.6/thebuggenie/wiki
Вот мой файл .htaccess:
# .htaccess file for The Bug Genie
# make sure that magic_quotes and register_globals is always off
<IfModule mod_php5.c>
php_flag magic_quotes_gpc off
php_flag register_globals off
</IfModule>
# rewrite rules
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase/
# Example:
# RewriteBase/
# or
# RewriteBase /dev/thebuggenie
# skip all hidden files (starting with a .)
RewriteCond %{REQUEST_URI} \..+$
RewriteCond %{REQUEST_URI} !\.(html|wsdl|json|xml)$
RewriteRule .* - [L]
# redirect to front controller
RewriteRule ^(.*)$ index.php?url=$1 [NC,QSA,L]
</IfModule>
# Stop people accessing directories they shouldn't have access to
RedirectMatch 403 ^/\.svn(/|$)
Спасибо за быстрый ответ .. ваш код работает отлично но мне нужно отфильтровать файлы утверждений, такие как css, js, images и т. д. С вашим кодом каждый URL-адрес переписывается с помощью index.php/**** –
Спасибо .... Теперь я получил его. –
Вы можете принять ответ, если это было полезно http://meta.stackexchange.com/a/5235/201107. @ baskar-m –