pratyushraj2225 Posted July 20, 2013 Share Posted July 20, 2013 To enable HTTPS in all pages of your prestashop website follow this 1. find your .htaccess file (usually in the root folder) 2. open the file ---- >FInd for "RewriteEngine on" if its off make it on 3. Under this write this below code RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://yoursitename.com/$1 [R,L] 4. Save and upload the file to respective directory NOTE: Extra rewriteRule may be present under "RewriteEngine on" Ignore do not modify until you understand it fully. 1 Link to comment Share on other sites More sharing options...
El Patron Posted July 20, 2013 Share Posted July 20, 2013 if you do this, then here is something to keep in mind http://www.prestashop.com/forums/topic/162017-tip-https-and-keep-alive-connections-persistant-connections/ Link to comment Share on other sites More sharing options...
vekia Posted July 20, 2013 Share Posted July 20, 2013 To enable HTTPS in all pages of your prestashop website follow this ... nice know how, thanks for sharing it but what when i regenerate the .htaccess file? then i have to change it once again 1 Link to comment Share on other sites More sharing options...
El Patron Posted July 21, 2013 Share Posted July 21, 2013 Hi vekia, you can keep custom .htaccess after regeneration in 1.5 if done correctly: http://www.prestashop.com/forums/topic/2131[spam-filter]tip-15-and-custom-htaccess/ for 1.4 you can use the back office to set custom directives so they are preserved across a regenerate 2 Link to comment Share on other sites More sharing options...
khairulaizat92 Posted August 3, 2013 Share Posted August 3, 2013 To enable HTTPS in all pages of your prestashop website follow this 1. find your .htaccess file (usually in the root folder) 2. open the file ---- >FInd for "RewriteEngine on" if its off make it on 3. Under this write this below code RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://yoursitename.com/$1 [R,L] 4. Save and upload the file to respective directory NOTE: Extra rewriteRule may be present under "RewriteEngine on" Ignore do not modify until you understand it fully. Hi vekia, you can keep custom .htaccess after regeneration in 1.5 if done correctly: http://www.prestasho...ustom-htaccess/ for 1.4 you can use the back office to set custom directives so they are preserved across a regenerate Hi there, thanks for your guys help,i finally all SSL was enable on my prestashop page. However there was another problem occured. some of my site page cant be access as it says "Not Found EROR 404" here are pat of my htaccess : <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{HTTP_HOST} ^store.globalsolution.com.my$ RewriteRule . - [E=REWRITEBASE:/] RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L] Then i replace it become like this: <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{SERVER_PORT} 80 RewriteRule . - [E=REWRITEBASE:/] RewriteRule ^(.*)$ https://store.yoursite.com.my/$1 [R,L] Is there any mistake i have done? My presta 1.4.5.0 Link to comment Share on other sites More sharing options...
vekia Posted August 3, 2013 Share Posted August 3, 2013 you said that some of my site page can you say something more about it? what pages exactly? product pages? category pages? maybe something else? Link to comment Share on other sites More sharing options...
khairulaizat92 Posted August 3, 2013 Share Posted August 3, 2013 you said that can you say something more about it? what pages exactly? product pages? category pages? maybe something else? Category Pages and Some of my products pages. Link to comment Share on other sites More sharing options...
pratyushraj2225 Posted August 3, 2013 Author Share Posted August 3, 2013 (edited) Try activating rewritebase for each url paths....example below,, hope this should help... # Activation of the URL Rewriting Options +FollowSymlinks RewriteEngine On # RewriteBase equivalent - Production RewriteCond %{HTTP_HOST} !^localhost$ RewriteRule . - [E=REWRITEBASE:/production/path/] # RewriteBase equivalent - Development RewriteCond %{HTTP_HOST} ^localhost$ RewriteRule . - [E=REWRITEBASE:/development/path/] # Rewriting RewriteRule ^(.*)$ %{ENV:REWRITEBASE}index.php?page=$1 [L] Edited August 3, 2013 by pratyushraj2225 (see edit history) Link to comment Share on other sites More sharing options...
khairulaizat92 Posted August 3, 2013 Share Posted August 3, 2013 Where to put that actually? Im using litespeed server by stablehost. And i have test it on every position, and its still make no changes. Oh yea, i want to correct my old comment, its not just Category and products, everything other than main page and back office, all become Error 404. Can i ask, whenever im clicking other pages on my site, why it became http instead https? Lets say, when im accessing my web, https://store.yoursite.com.my then i want to go to antivirus products category, it suddenly changes it self like being force to http://store.yoursite.com.my/antivirus even when i put https:// manually like this "https://store.yoursite.com.my/antivirus" it will automatically remove "s" and become only http. is this normal? Im sorry for asking so many question due to im just a newbie Link to comment Share on other sites More sharing options...
pratyushraj2225 Posted August 3, 2013 Author Share Posted August 3, 2013 (edited) the 's' is replaced because the https is not activated in that page, In many cases, you can also just add these lines vbelow to a file named .htaccess in the folder that you want to redirect http to https. RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} remember add .htaccess file to each folder which you want to be https. You can also redirect a single page from http to https in server by using this in your configuration file or .htaccess file: RewriteEngine On RewriteRule ^apache-redirect-http-to-https\.html$ https://www.yoursite...p-to-https.html [R=301,L] Repeat the above 2nd line for every url which you want to be https. Look in your control panel for ssl and try to activate the ssl for every domain. Edited August 3, 2013 by pratyushraj2225 (see edit history) Link to comment Share on other sites More sharing options...
khairulaizat92 Posted August 4, 2013 Share Posted August 4, 2013 Hi Thanks For your help, I finally solve this I did go through some of the details your given and also found a tutorial for regenerate .htaccess file here. http://mypresta.eu/en/art/basic-tutorials/how-to-regenerate-htaccess-in-prestashop-1-5.html But id didnt do much help, until i found an option at backoffice>seo&Url I do some test on turning on and off for these option then finally i can use the https on others page: Friendly URL : YES Ascented URL : NO Automatically redirect to the canonical URL : NO Disable apache multiviews : NO Disable apache mod security : YES Then finally i replacing the default Review Code <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{HTTP_HOST} ^store.globalsolution.com.my$ RewriteRule . - [E=REWRITEBASE:/] RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L] Then i replace the code With the one you given earlier: <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://store.globalsolution.com.my/$1 [R,L] And Suddenly, Everything go smooth and every page are enables with SSL. Mission Completed, thanks For your guys help 1 Link to comment Share on other sites More sharing options...
vekia Posted August 4, 2013 Share Posted August 4, 2013 hello community so whole problem is solved now? Link to comment Share on other sites More sharing options...
THaus Posted August 5, 2013 Share Posted August 5, 2013 I do have a similar problem where I can't access any of the categories etc other than the home page. I have a test site running prestashop. The main URL is not redirected yet since we are running aspdotnetstorefront on a different server. I encounter problems testing some modules and the navigation. One suggestion from prestashop staff was: Module doesn't work as on the server there is a redirect (.htaccess file) of all requests from http://198.252.65.104/~tth/shop/ to http://theteahaus.com/shop/ without taking subcatologues, i.e.the request is sent not to http://theteahaus.com/shop/modules/producttabs/ajax.php but to http://theteahaus.com/shop/ and it doesn't get a reply. You need to set the redirect properly on the server. I am just not sure how do properly redirect it on the server without redirecting our current site. Any suggestions? Link to comment Share on other sites More sharing options...
emvoo Posted August 11, 2013 Share Posted August 11, 2013 To enable HTTPS in all pages of your prestashop website follow this 1. find your .htaccess file (usually in the root folder) 2. open the file ---- >FInd for "RewriteEngine on" if its off make it on 3. Under this write this below code RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://yoursitename.com/$1 [R,L] 4. Save and upload the file to respective directory NOTE: Extra rewriteRule may be present under "RewriteEngine on" Ignore do not modify until you understand it fully. It doesnt work on my shop i get an error: "To many redirections" or similar cant remember now. 1 Link to comment Share on other sites More sharing options...
khairulaizat92 Posted September 2, 2013 Share Posted September 2, 2013 Hi there guys, now im back with a new problem; once before i can force ssl on my web page and on every each of them, but after upgrading to 1.5.5 it seems, i cant do it again, if im using the old configuration previously im using, it will causes redirect loop on my web. My original htaccess contains: <IfModule mod_rewrite.c>RewriteEngine onRewriteCond %{HTTP_HOST} ^store.globalsolution.com.my$RewriteRule . - [E=REWRITEBASE:/]RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L]Then i replace it become like this:<IfModule mod_rewrite.c>RewriteEngine onRewriteCond %{SERVER_PORT} 80RewriteRule . - [E=REWRITEBASE:/]RewriteRule ^(.*)$ https://store.globalsolution.com.my/$1 [R,L] Actually, I didn't want to update my previous presta version, but what happened is, i unable to access my back office. I can enter the username and pass page, but then suddenly everything is plain white. blank. so i have to update it to fix whatever error that mysteriously occured. So now, after the update, i cant force the ssl on my site. hope can help Link to comment Share on other sites More sharing options...
khairulaizat92 Posted September 3, 2013 Share Posted September 3, 2013 Can anyone? helping me? Link to comment Share on other sites More sharing options...
khairulaizat92 Posted September 3, 2013 Share Posted September 3, 2013 bump need help Link to comment Share on other sites More sharing options...
roband Posted September 3, 2013 Share Posted September 3, 2013 I believe the redirect-logic using .htaccess worked more by accident than by design in older releases, and that Prestashop changed in 1.5.5 so it accidentally stopped working. Changes are needed in Prestashop core to fix this, it's tracked in http://forge.prestashop.com/browse/PSCFV-6689 but not much progress seems to be made. Cheers, Robert. 1 Link to comment Share on other sites More sharing options...
khairulaizat92 Posted September 3, 2013 Share Posted September 3, 2013 I believe the redirect-logic using .htaccess worked more by accident than by design in older releases, and that Prestashop changed in 1.5.5 so it accidentally stopped working. Changes are needed in Prestashop core to fix this, it's tracked in http://forge.prestashop.com/browse/PSCFV-6689 but not much progress seems to be made. Cheers, Robert. Not to much i think, its stopped at 1.4.9.0, and even if i want to give it a try, its already proven there, even in an upgrade between 1.4.x.x - 1.4.9.0 its already have a BIG DIFFERENCES. So which is, logically impossible to be the same in 1.5.5.0 Maybe thinking on changing to ocart if these issu cant be solve Link to comment Share on other sites More sharing options...
Miguel Alonso Posted September 14, 2013 Share Posted September 14, 2013 Yo tenia un problema parecido y era simplemente algunas imagenes que no estaban nombradas correctamente al subirlas y ponerles los links. Ej.- imagen de cms en vez de ponerle: https://www.miweb.x/img/x.png le ponia http.. Para averiguar esto existe una herramienta muy util que te da los resultados de lo que no esta dentro del https. Visite http://www.whynopadlock.com/ Link to comment Share on other sites More sharing options...
nathanielleee Posted February 12, 2014 Share Posted February 12, 2014 i am looking to redirect a product page simply to include the category in the link. For example: www.ApostolicClothing.com/iris.html should be www.ApostolicClothing.com/skirts/iris.html Hope that makes sense. I know how to change the SEO to include the category but due to our social media presence, i dont want all of our outside links to go bad. ANY HELP WOULD BE APPRECIATED. Link to comment Share on other sites More sharing options...
ivdisplays Posted March 1, 2014 Share Posted March 1, 2014 I am having a similar problem, please look at the attachment. If you see, there is a yellow triangle next to the icon. The developer followed this thread and modified the .htaccess. We are also having issues at the backend entering secured information. We need to resolve this issue, any help. Link to comment Share on other sites More sharing options...
pixelmatto Posted April 22, 2014 Share Posted April 22, 2014 I am having a similar problem, please look at the attachment. If you see, there is a yellow triangle next to the icon. The developer followed this thread and modified the .htaccess. We are also having issues at the backend entering secured information. We need to resolve this issue, any help. We have the same problem, any helps please? we try to modify file .htaccess in root / but the result is the same.....any tips please? Link to comment Share on other sites More sharing options...
vekia Posted April 22, 2014 Share Posted April 22, 2014 you see there yellow unlock because of unsecured contents. what files are loaded without ssl ? Link to comment Share on other sites More sharing options...
pixelmatto Posted April 23, 2014 Share Posted April 23, 2014 you see there yellow unlock because of unsecured contents. what files are loaded without ssl ? A lot of images, this is a report from google chrome: "The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/img/logo.jpg?1398198601': this content should also be loaded over HTTPS. (index):1 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/img/logo.jpg?1398198601': this content should also be loaded over HTTPS. (index):5 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/homeslider/images/b26b5eb46cee329fcad266051decad18.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/homeslider/images/2183f3f1796e4273d7bbb73857704ca3.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/homeslider/images/7560d1a458c8f66c51da53fad587a555.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/blockreinsurance/img/reinsurance-1-1.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/blockreinsurance/img/reinsurance-2-1.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/blockreinsurance/img/reinsurance-3-1.jpg': this content should also be loaded over HTTPS. (index):15 The page at 'https://www.pixelmatto.com/' was loaded over HTTPS, but displayed insecure content from 'http://www.pixelmatto.com/modules/blockreinsurance/img/reinsurance-4-1.jpg': this content should also be loaded over HTTPS. " Link to comment Share on other sites More sharing options...
vekia Posted April 23, 2014 Share Posted April 23, 2014 ok i see, this problem was discussed several times on forum, reinsurance images also :-) http://www.prestashop.com/forums/topic/303364-header-logo-breaks-ssl/ Link to comment Share on other sites More sharing options...
pixelmatto Posted April 23, 2014 Share Posted April 23, 2014 ok i see, this problem was discussed several times on forum, reinsurance images also :-) http://www.prestashop.com/forums/topic/303364-header-logo-breaks-ssl/ vekia, thank you so much, It driven me crazy! Thank you again vekia! Have a great day! Link to comment Share on other sites More sharing options...
vekia Posted April 23, 2014 Share Posted April 23, 2014 so you found solution in topic that i provided above? Link to comment Share on other sites More sharing options...
pixelmatto Posted April 24, 2014 Share Posted April 24, 2014 yes, exactly here: here it is: https://github.com/P...e3e82cedf85aad3 Link to comment Share on other sites More sharing options...
mir-aus Posted September 15, 2014 Share Posted September 15, 2014 hi, I have more than 10,000 products, I have some img in product description which I use http links before. and way I can type SQl in my myphp to change all link with http to https > i don't know how can I type the SQL code. Link to comment Share on other sites More sharing options...
Greu Posted August 30, 2015 Share Posted August 30, 2015 HI I'm trying to fix a canonical url issue (http/https duplicates). I was playing with your solutions to shift all product urls in https when I discovered that some misconfiguration probably creeped in somewhere. I added 1 line to .htaccess : RewriteEngine onRewriteCond %{HTTP_HOST} ^mydomain$RewriteRule ^(.*)$ https://mydomain/$1 [R,L]RewriteRule . - [E=REWRITEBASE:/Base/]RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L] It works like a charm : all urls are httpsed ! 1 line was not enough though... No https product page is found on the server (+ error message). SSL certificate is installed and valid. PS configuration with Domain SSL + set to 1 for SSL. https://mydomain/Base/ works fine as well as https://order & payment pages. Why not the product pages ? Any clue where to look would be GREAT !!! Always humbly drinking your Light from above Link to comment Share on other sites More sharing options...
vekia Posted August 31, 2015 Share Posted August 31, 2015 you mean that you cant open product pages with secured connection? or you've got yellow padlocK? Link to comment Share on other sites More sharing options...
Greu Posted August 31, 2015 Share Posted August 31, 2015 I can't open product pages with secured connection it is like they do not exist at all on the server, although the url is correctly written (+ preceeded with https) I'm not privy enough with the mechanics of PS yet to have a clue where to dig in at that point do you see some track to follow ? Link to comment Share on other sites More sharing options...
Greu Posted September 4, 2015 Share Posted September 4, 2015 ↑ 1 Link to comment Share on other sites More sharing options...
Recommended Posts