Almarma Posted November 5, 2013 Share Posted November 5, 2013 (edited) Hi everybody, I started a shop called nordicvapor.com, and I created and installed Prestashop on it like that: nordicvapor.com. Well, for different reasons (to enable a better functionality with Cloudflare), I want to enable the www. prefix to my site. The main URL keeps working (www.nordicvapor.com), but all the other direct links to categories and/or products are broken, and it is a SEO disaster, as all my Google results are broken with a 404 error (I'll leave it on today so you can check, but after today I'll revert back to the URL without www. if I cannot fix it). Also, if I type nordicvapor.com (without www.), it's broken too. You can check the errors here: https://www.google.com/?gws_rd=cr&ei=fdd4UvvgE8ng4QSznICICg#q=site:nordicvapor.com All the results are broken!! I suspect it's something wrong with .htaccess redirection, so after clearing PS cache, I also renamed the previous .htaccess, and saving again the preferences under SEO & URLs, a new one was created, and the issue is still there. What can I do to fix it? Just for information: I own some other domains hosted in the same server using Wordpress. I recently updated those to use www. too, without a single problem. Does anyone has a clue about what can I do to fix it? I'm using Prestashop 1.5.5.0 Thank you in advance Edited November 5, 2013 by Almarma (see edit history) Link to comment Share on other sites More sharing options...
Almarma Posted November 5, 2013 Author Share Posted November 5, 2013 OK, I fixed it myself just adding: RewriteEngine On RewriteCond %{HTTP_HOST} ^nordicvapor.com [NC] RewriteRule ^(.*)$ http://www.nordicvapor.com/$1 [L,R=301] Shouldn't this came by default generated by Prestashop itself? I think it would help to avoid URL issues. I mean, if inside PS preferences, I set the URL as www.domain.com, PS generates this two lines: RewriteEngine On RewriteCond %{HTTP_HOST} ^domain.com [NC] RewriteRule ^(.*)$ http://www.domain.com/$1 [L,R=301] But if I add domain.com (without www.), it should create the opposite: RewriteEngineOn RewriteCond %{HTTP_HOST} ^www.domain.com [NC] RewriteRule ^(.*)$ http://domain.com/$1 [L,R=301] Just an idea to help improving PS Link to comment Share on other sites More sharing options...
Recommended Posts