Mac OSX –リダイレクト.htaccessが機能しませんか?
これが.htaccess
ファイルです。
/Library/WebServer/Documents/.htaccess
# BEGIN WordPressRewriteEngine On RewriteBase /example/ RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /example/index.php [L] # END WordPress
溶液
/etc/apache2/httpd.conf
でApache構成ファイルを見つけ、次の設定が正しく構成されていることを確認します。
1. mod_rewrite.so
がロードされます。
2。 Directory
タグで、AllowOverride
をall
に更新します(デフォルトはなし)
sudo vim /etc/apache2/httpd.conf
# Make sure below module "mod_rewrite.so" is loaded. LoadModule rewrite_module libexec/apache2/mod_rewrite.so LoadModule php5_module libexec/apache2/libphp5.so #LoadModule perl_module libexec/apache2/mod_perl.so LoadModule hfs_apple_module libexec/apache2/mod_hfs_apple.so #... DocumentRoot "/Library/WebServer/Documents"#... # # AllowOverride controls what directives may be placed in .htaccess files. # It can be "All", "None", or any combination of the keywords: # AllowOverride FileInfo AuthConfig Limit # AllowOverride all #...