Назад | Перейти на главную страницу

Проблема с Mod_rewrite при настройке на Snow Leopard

Возможный дубликат:
Все, что вы хотели знать о правилах Mod_Rewrite, но боялись спросить?

Я вернулся к этому, потому что на долгие годы был в стороне от других вещей. Итак, пожалуйста, найдите мои данные ниже, с этими данными я все еще получаю следующую ошибку:

   500 Internal Server Error

   The server encountered an internal error or misconfiguration and was unable to complete your request.

   Please contact the server administrator, you@example.com 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.

мой URL:

  localhost/exp/index.php 

Мой htaccess:

  RewriteEngine On
  RewriteRule (.*?)/(.*?)/(.*?)$
  exp/index.php?page=$1&action=$2&id=$3

Теперь, если я закомментирую все, кроме RewriteEngine On

  RewriteEngine On
  #RewriteRule (.*?)/(.*?)/(.*?)$
  #exp/index.php?page=$1&action=$2&id=$3

Подробности моего файла /etc/apache2/httpd.conf приведены ниже:

 <Directory />
     Options Indexes MultiViews FollowSymlinks
     AllowOverride All
     Order allow,deny
     Allow from all
 </Directory>


 <Directory "/Library/WebServer/Documents/">
   Options Indexes MultiViews FollowSymlinks
   AllowOverride All
   Order allow,deny
   Allow from all
 </Directory>

Mac Snow Leopard. Мой каталог находится в DocumentRoot "/ Library / WebServer / Documents", и я не использую обычный http: // localhost / ~ Пользователь / но http: // localhost /?? и т.д

Это может или не может, но просто заметил, что если я перечисляю свои каталоги, просто перейдя на localhost, тогда папка, которую я использую, не отображается ??? в списке других папок

Так что к жизни я не знаю, что происходит.

Пытаться:

  RewriteEngine On
  RewriteRule ^(.*?)/(.*?)/(.*?)$ /exp/index.php?page=$1&action=$2&id=$3