0

だから私はコハナを使っています。あなたがそれを知っていれば便利ですが、私を助ける必要はありません。

次のmod_rewriteルールがあります。

# Allow any files or directories that exist to be displayed directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/store/.*$

# Rewrite all other URLs to index.php/URL
RewriteRule .* index.php [L]

そのため、に存在しないファイルとディレクトリに対するすべてのリクエストを書き直そうとしていますindex.php

mydomain.com/store/*ただし、ディレクトリ内に別のhtaccessファイルがあり、そこで機能するため、送信されたすべてのリクエストを通過させたいと思いますstore。現時点では機能していないようです。何か案は?

フルhtaccess:

# Turn on URL rewriting
RewriteEngine On

# Installation directory
RewriteBase /

#ErrorDocument 404 http://www.mydomain.com/404Page.html
#Options +FollowSymlinks

# Protect hidden files from being viewed
<Files .*>
    Order Deny,Allow
    Deny From All
</Files>


RewriteCond %{REMOTE_ADDR} !^myip
RewriteCond %{REQUEST_URI} !^/maintenance\.html$
RewriteRule ^(.*)$ http://www.mydomain.com/maintenance.html [R=307,L]

##301 Redirect Rules##
#some 301 redirects i did not include here

##Kohana Redirect Rules##

# Protect application and system files from being viewed
RewriteRule ^(?:application|modules|system|kohana|vendors)\b.* http://www.mydomain.com/ [L]

# Allow any files or directories that exist to be displayed directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/?store/

# Rewrite all other URLs to index.php/URL
RewriteRule .* index.php [L]
4

2 に答える 2

0

store問題は、webroot のファイルではなく、ディレクトリの .htaccess ファイルにあることが判明しました。ありがとう、そして私の愚かさを申し訳ありません。将来のユーザーのためにこの性質のものをデバッグする方法についてコメントを残したい場合は、それが素晴らしいでしょう。

于 2013-02-14T19:02:38.037 に答える