Opencart的.htaccess问题问题、Opencart、htaccess

2023-09-02 11:41:12 作者:美好的那么不真实

我有类似的问题,我的网址是像name.domain.com/subdoamin/store/index.php?...

I'm having similar problem My url is like name.domain.com/subdoamin/store/index.php?...

和我的htaccess的文件是:

and my htaccess file is :

Options +FollowSymlinks

# Prevent Directoy listing 
Options -Indexes

# Prevent Direct Access to files
<FilesMatch ".tpl">
 Order deny,allow
 Deny from all
</FilesMatch>

#<FilesMatch ".ini">
 #Order deny,allow
 #Deny from all
#</files>

# SEO URL Settings
RewriteEngine On
RewriteBase /store/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#RewriteRule ^(.*)?*$ index.php?_route_=$1 [L,QSA]
RewriteRule ^(.*) index.php [L,QSA]

但它是给人一种 404未发现错误

推荐答案

如果您的存储文件夹里面的子域名的文件夹,您的的RewriteBase 应 /子域/存储/

If your store folder is inside the subdomain folder your RewriteBase should be /subdomain/store/