2016-09-15 112 views
0

我改變我的網站從http到HTTPS和Lets Encrytp。現在我無法訪問我的Magento管理控制檯。我讀過這是因爲.htaccess文件。許多重定向錯誤.htaccess Magento

<IfModule mod_rewrite.c> 

############################################ 
## enable rewrites 

    Options +FollowSymLinks 
    RewriteEngine on 

############################################ 
## you can put here your magento root folder 
## path relative to web root 

    #RewriteBase /magento/ 

############################################ 
## workaround for HTTP authorization 
## in CGI environment 

    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] 

############################################ 
## TRACE and TRACK HTTP methods disabled to prevent XSS attacks 

    RewriteCond %{REQUEST_METHOD} ^TRAC[EK] 
    RewriteRule .* - [L,R=405] 

############################################ 
## redirect for mobile user agents 

    #RewriteCond %{REQUEST_URI} !^/mobiledirectoryhere/.*$ 
    #RewriteCond %{HTTP_USER_AGENT} "android|blackberry|ipad|iphone|ipod|iemobile|opera mobile|palmos|webos|googlebot-mobile" [NC] 
    #RewriteRule ^(.*)$ /mobiledirectoryhere/ [L,R=302] 

############################################ 
## never rewrite for existing files, directories and links 

    RewriteCond %{REQUEST_FILENAME} !-f 
    RewriteCond %{REQUEST_FILENAME} !-d 
    RewriteCond %{REQUEST_FILENAME} !-l 

############################################ 
## rewrite everything else to index.php 

    RewriteRule .* index.php [L] 

</IfModule> 

你能告訴我我必須改變嗎?我在Web開發方面不太擅長。

回答

0

如果遇到錯誤,如,過多的重定向對你的Magento商店,那麼問題是因爲你的.htaccess文件或你的緩存文件夾中。

廣場.htaccess從一個新鮮的Magento包的新副本,刪除緩存和會話文件夾以及。然後刷新,它應該是好的。

或者另一種方式是,

core_config_data表中刪除的web/cookie/cookie_domain值,並設置web/cookie/cookie_httponly」到0。通過刪除var/cache中的文件來清除緩存。也清除從Magento管理面板緩存

+0

嗨,所以我做了上述事情。仍然不起作用。我把一個新的'.htaccess'文件放到我的Webdirectory中。還清理了我的'/ var/cache',但沒有'/ var/session'。 在'core_config_data'表中不包含'web/cookie/cookie_domain'或'web/cookie_cookie_httponly'的記錄。我發現這個錯誤只出現在管理面板上,但商店頁面可以正常工作。 – RafnexJr