私は駐留プラットフォームhttp://example.comにある駐車ドメインhttp://example2.comを持っています。.htaccessメインドメインはサブフォルダにありますが、サブフォルダにはまだ到達可能です
http://example2.com/example2/frに行った場合、私はhttp://example2.com/frにリダイレクトされず、解決策を試しましたが、リダイレクトループが発生しています。 public_htmlのフォルダで
> public_html
- .htaccess
- index.php
> assets
> css
> js
> example2
- .htaccess
- index.html
> fr
- index.html
> en
- index.html
用のファイルとサブフォルダ/例2は今、public_htmlのフォルダに、私の.htaccessファイルでの私のリダイレクトルールがありますされています
<IfModule mod_rewrite.c>
RewriteEngine on
# Redirect the example2 to the subfolder /example2
RewriteCond %{HTTP_HOST} ^(www\.)?example2\.com$ [NC]
RewriteRule !^example2/ /example2%{REQUEST_URI} [L,NC]
</IfModule>
/example2フォルダで、私のhtaccessファイルは次のようにリダイレクトされます。
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
RewriteRule ^index\.html$/[R=301,L]
RewriteRule ^(.*)/index\.html$ /$1 [R=301,L]
#RewriteRule ^(.*)$ /$1 [R=301,L]
</IfModule>
/subfolder/.htaccessを削除するとどうなりますか? – starkeen