Jump to content

Https not working on inner pages then homepage


Recommended Posts

I have installed ssl on my site. And wrote correct code which I am using for many other sites to redirect site from http to https.

 

When I am checking on current prestashop site only main page is working with https. I am not able to work https in inner pages.

 

Even I am just trying to add https://mydomain.com OR https://mydomain.com in url its working fine.

 

But

 

If I do same thing in any inner pages then its automatically redirecting to http not on https. (Even I type manually https in URL its redirecting me to http then HTTPS).

 

So, I am really tired since last 3 days to working on this issue.

 

Please help me to resolve this issue asap.

Link to comment
Share on other sites

Thanks for your reply!

Yes I am using. I tried what you said but when I looked in admin side its showing like this.

 

In preferences->SEO and URL's section.

URL rewriting is not activated on your server, or its not possible to check your server configuration. if you wants to use frieldly url you must activate it.

 

Also when I tried to print PHPINFO there is no such rewrite module enabled so do I need to ask my hosting provider to do it as I have shared hosting?

Link to comment
Share on other sites

  • 1 month later...

The site URL is http://bmx24seven.com/

 

I removed the ssl certicate for now

 

I really need an solution for this, I want to set ssl only to the checkout pages.

 

What I experianced is that the : is not in the URL of the innerpages whet I put this : in the address bar off the shop it works fine. 

Edited by WilkoHartung (see edit history)
Link to comment
Share on other sites

My .htaccess file looks like this.

 

 

# ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
 
<IfModule mod_rewrite.c>
 
# Disable Multiviews
Options -Multiviews
 
RewriteEngine on
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule . - [E=REWRITEBASE:/]
RewriteRule ^api/?(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L]
 
# Images
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$1$2$3.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$1$2$3$4.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$1$2$3$4$5.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$1$2$3$4$5$6.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6$7.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7$8.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8$9.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9$10.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^c/([0-9]+)(\-[\.*_a-zA-Z0-9-]*)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2$3.jpg [L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^c/([a-zA-Z_-]+)(-[0-9]+)?/.+\.jpg$ %{ENV:REWRITEBASE}img/c/$1$2.jpg [L]
# AlphaImageLoader for IE and fancybox
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^images_ie/?([^/]+)\.(jpe?g|png|gif)$ js/jquery/plugins/fancybox/images/$1.$2 [L]
 
# Dispatcher
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^.*$ - [NC,L]
RewriteCond %{HTTP_HOST} ^bmx24seven.com$
RewriteRule ^.*$ %{ENV:REWRITEBASE}index.php [NC,L]
</IfModule>
 
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType image/png "access plus 1 month"
ExpiresByType text/css "access plus 1 week"
ExpiresByType text/javascript "access plus 1 week"
ExpiresByType application/javascript "access plus 1 week"
ExpiresByType application/x-javascript "access plus 1 week"
ExpiresByType image/x-icon "access plus 1 year"
</IfModule>
 
FileETag INode MTime Size
<IfModule mod_deflate.c>
<IfModule mod_filter.c>
AddOutputFilterByType DEFLATE text/html text/css text/javascript application/javascript application/x-javascript
</IfModule>
</IfModule>
 
#If rewrite mod isn't enabled
ErrorDocument 404 /index.php?controller=404
 
# ~~end~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
Link to comment
Share on other sites

  • 1 month later...

I'm having the same problem, but I can't afford to disable SSL, anyone else having this issue? Running PS v1.5.6..

 

Edit: In General activate ssl, in SEO settings, remove http and https from domain url. This made it work for me.

 

I'm still experiencing redirect loops, but that seems to be an another issue.

 

Edit2: I solved it by disabling apache multiviews, took time to find the problem, but when found everything made sense :)

Edited by _Zico_ (see edit history)
Link to comment
Share on other sites

  • 1 year later...
  • 2 weeks later...

@ShiftCTRL: as far as I can see you don't have any ssl setup (on presta at least), nor friendly urls, can you try activating both from the back office?

 

Nemo, I've enabled the store, turned on Friendly URLs and SSL is setup on login pages/ checkout [Re: stilest.com] 

 

The site was working fine previously even after the upgrade. Not sure what happened one day the site was put under maintenance then taken off, and next thing you know I started having this problem. 

 

Looking in Chrome's console you'll see:

Failed to load resource: net::ERR_NAME_NOT_RESOLVED
http://http//www.stilest.com/?live_configurator_token=929cf8dbf6e3cbf9c9bf78d8b5a97424&id_employee=2&id_shop=1 
 
Failed to load resource: net::ERR_CACHE_MISS
http://http//www.stilest.com/?live_configurator_token=929cf8dbf6e3cbf9c9bf78d8b5a97424&id_employee=2&id_shop=1:1
 
It seems the problems has something to do with the SEO/URLS setting.
Either:
1) It's adding the protocol twice and the second instance has the colon removed from the string. 
 
 
I'm just speculating here, but I find this odd that I can't find many others with this problem. The couple instances I found on the web, went unaddressed. 
 
I'm still a rookie when it comes to Prestashop, so please let me know if there's any other data I can provide to help debug this?
 
[uPDATE] Solved
 
So after writing my reply to you it dawned on me, the problem may be that I'm not to specify the protocol at all. So I removed it and the problem's fixed. 
 
Thanks the help nonetheless!
 
Just to  be clear for anyone else who runs into this problem. 
 
Edited by ShiftCTRL (see edit history)
  • Like 1
Link to comment
Share on other sites

×
×
  • Create New...