xserverでhtaccessのmod_rewriteがうまくいかない。
きました。むだ時間シリーズ。
エックスサーバーでhtaccessのmod_rewriteがうまくいかない。
sv7Xぐらいのようだ。
そもそも、mysql5にしないと厳しかった。
sqliteは、ゴニョゴニョしてみたけど、諦めた。
はい。12じか〜ん。
そして、本題のmod_rewrite設定。
これは、ホスティング毎にめんどいね。
●XSERVERのHTTP接続の時。
アクセスURL例
http://www.example.com/foo/ctrl1/mber1/
config.php
$config['base_url'] = "http://www.example.com/foo/";
$config['index_page'] = "";
$config['uri_protocol'] = "REQUEST_URI";
$config['url_suffix'] = "";
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
/foo/.htaccess
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/system.*
RewriteRule ^(.*)$ index.php?/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ index.php?/$1 [L]
うまくいってたとおもってたら、うまくいってなかった。。。orz
誰か教えてください。
4時間ぐらいで諦めた。たぶん。
。