Re: can't login after adding www to https setting in config.php
in your config.php
$xcart_http_host ="www.yourdomain.com";
$xcart_https_host ="www.yourdomain.com";
then put the folowing in your .htaccess just before your DirectoryIndex line (if your have installed x-cart in root)
<IfModule mod_rewrite.c>
RewriteBase /
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTPS} on
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ https://www.%{HTTP_HOST}/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteBase /
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.yourdomain\.com$ [NC]
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
</IfModule>
__________________
X-Cart 4.1.5
PHP 4.3.9
Mysql 4.1
VPS CentOS 4.2
Mods: Too much...
* Moving to 4.1.8 and to a dedicated server *
|