2

we are using https for secure pages.

we can see http for unsecure pages - products and catalog pages.

we can see https for secure pages - My account, Login pages.

But if we manually type https:// for home , catalog & product pages, its redirecting to https only. but i want to redirect to http

before home page, catalog & product pages are in https.

i followed this in .htaccess:

#Redirect your Homepage from HTTPS to HTTP
RewriteCond %{HTTPS} on
RewriteRule ^$ http://%{HTTP_HOST} [L,R]

source : http://www.activo.com/redirect-https-to-http-for-any-homepage/

Than home page is working fine.

if we manually type https://example.com for home page ,its rediretcting to http://example.com. It's fine

what i have to do for catalog & product pages.

enter image description here

4
  • have you set https for both secure & unsecure url at magento setting?
    – Amit Bera
    Commented Dec 28, 2015 at 8:22
  • no, i have set only for secure pages. Commented Dec 28, 2015 at 8:25
  • Please check updated image in question Commented Dec 28, 2015 at 8:27
  • it possible.. i will do
    – Amit Bera
    Commented Dec 28, 2015 at 9:56

2 Answers 2

1

Method 1: You may try this as well. It is specifically targeting your catalog and product page with help of editing .htaccess

    RewriteEngine On
    RewriteCond %{HTTPS} on
    RewriteEngine On

    # From https to http
    RewriteCond %{REQUEST_URI} !^/catalogpage/
    RewriteCond %{REQUEST_URI} !^/productpage/
    RewriteRule ^(.*)$ http://%{HTTP_HOST} [L,R=301]

And set "Auto-redirect to Base URL" to NO under System -> Configuration -> Web -> Url Options

Method 2: Please visit following tutorial about redirecting https to http on catalog and product page:

https://www.designhaven.co.uk/2013/06/redirecting-secure-https-non-secure-http-magento/

9
  • i tried your method 1 by replacing example.com to our site name. . but now if we type product-url or category-url , its redirecting to home page Commented Dec 28, 2015 at 12:56
  • @BabyinMagento Answer edited, check it out now or try method 2. Commented Dec 28, 2015 at 12:59
  • Method 2 is working. Thanks for your support. Commented Dec 28, 2015 at 13:37
  • @BabyinMagento Your welcome. Commented Dec 28, 2015 at 13:38
  • i used the above link to get an answer, but in if we go for checkout page, i am getting this error : Fatal error: Call to undefined method Mage_Core_Controller_Varien_Router_Standard::_getCurrentSecureUrl() in in standard.php Commented Dec 29, 2015 at 9:47
2

Please consider provide all pages via https It will make your visitors feel more secure. Plus... Google ranks https site slightly higher then http sites. Choose one protocol... Http or https. Not both.

3
  • +1 from me. Thanks for your tips.but our senior members don't agree for this for seo purpose . but you are right https is better for seo. Commented Dec 28, 2015 at 18:14
  • 1
    not only for SEO also for security for your visitors. Imagine the following setting: Your customer uses a public free wifi. A man in the middle might not be able to trace his activities on your checkout pages (https protected) but he can built a profile for every non-https page your customer visits. Using this profile the man in the middle can try to tempt your customer to visit a phishing page and hack your customers account. Use HTTPS for the entire site... no only for better SEO purposes but more important for security reasons.
    – hans2103
    Commented Dec 28, 2015 at 19:39
  • sure, we will go for https. Commented Dec 29, 2015 at 4:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.