Jump to content

i get "too many redirects" error on my front shop page


Recommended Posts

i just installed prestashop v 1.4.8.2.

the backshop works fine. but i get this error when i open the front shop:

 

 

This webpage has a redirect loop

The webpage at http://flowermagics.com/ has resulted in too many redirects. Clearing your cookies for this site or allowing third-party cookies may fix the problem. If not, it is possibly a server configuration issue and not a problem with your computer.

Here are some suggestions:

Error 310 (net::ERR_TOO_MANY_REDIRECTS): There were too many redirects.

Please give some solution.

Link to comment
Share on other sites

This is usually due to a.htaccess error if you are on a Linux style server. Try deleting your .htaccess file and regenerating it from the back office: Tools -> Generators then click button "Generate .htaccess file".

Link to comment
Share on other sites

Sorry - I should have said - it's a hidden file.

 

There is usually an option on the ftp program to view hidden files

 

Dreamweaver etc., has an option "view hidden files"

 

Type "view hidden files ftp" into Google for more info.

 

Hidden files may not show up in certain ftp programmes: Filezilla has problems displaying hidden files. But it should be in the root of the folder you installed PS in i.e. not inside any subfolders.

 

If you cannot see the .htaccess to delete it try creating a new one with the Generator - hopefully this should overwrite it.

Link to comment
Share on other sites

In preferences i selected SEO n URL>>Automatically redirect to canonical url>>YES

after that its displaying a white page. i have selected NO now and its showing the same error.

i tried searching for .htaccess but couldnt find the hidden file.

 

@dhurley : you mean to say i must upgrade from 1.4.8 to 1.5.0?

Link to comment
Share on other sites

The setting might not be available in 1.4.8. Don't know I have not used it.

 

In 1.5 the setting is called "disable multiviews" if you do the research you will find yourself wondering why anybody would turn this off. In a nutshell Google Bot has a hard time crawling sites that have apache multiview enabled.

 

.htaccess is a hidden file. In your ftp program if you have a command window use "-a" or show all. Or look for an option to show hidden files. This file needs to have the correct permissions (chmod 777 something other than 777 might work 755 or 766). But prestashop writes its own .htaccess files. If prestashop cannot open and change that file, then seo friendly urls and other things will not work.

 

Canonical urls:

if a user visits

/page1.php?id=3

and this setting is enabled they should be redirected to the "rewritten" address for that same page or:

/our-favorite-page-3

 

These settings are not the same they are related. Would I recommend upgrading to 1.5? No, not until they have a stable release. Right now it is in "Release Candidate" this is closer than "Beta" but, if you are not a programmer, I would wait.

 

You might have to disable multiviews in your apache configuration (/etc/apache2/httpd.conf) or it might be in php.ini.

Link to comment
Share on other sites

  • 2 months later...
  • 3 years later...

In Prestashop 1.5

 

Preferences -> SEO & URL's

 

Set this to YES

 

Disable apache multiviews

nable this option only if you have problems with URL rewriting on some pages.

 

 

I can't get access to my Prestashop homepage nor CMS.

 

The error message I receive is: ERR_TOO_MANY_REDIRECTS.

 

I tried to publish my website by just changing the HOME directory name of my prestashop instance.

 

How could I fix this? HELP!!!

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

I was finally able to solve my problem by:

 

1) setting the new shop address in the SEO & URL module

2) setting the right home path (this was wrong) in the SEO & URL module

3) remove the .htaccess file from the host home directory

 

Thanks anyway!

Link to comment
Share on other sites

  • 6 months later...

I had the same problem:

loser@brick:/tmp# wget  https://server.com/prestashop/index.php
--2017-02-23 21:59:36--  https://server.cl/prestashop/index.php
Resolving server.cl (server.cl)... 190.46.26.35
Connecting to server.cl (server.cl)|190.46.26.35|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: http://server.cl/prestashop/index.php [following]
--2017-02-23 21:59:37--  http://server.cl/prestashop/index.php
Connecting to server.cl (server.cl)|190.46.26.35|:80... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://server.cl/prestashop/index.php [following]
--2017-02-23 21:59:37--  https://server.cl/prestashop/index.php
Connecting to server.cl (server.cl)|190.46.26.35|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: http://server.cl/prestashop/index.php [following]
...

Note how it was redirecting from https://server.cl/prestashop/index.php to http://server.cl/prestashop/index.php and then from http://server.cl/prestashop/index.php to https

 

My Nginx config had a rule to rewrite all urls as https, and Prestashop's defaults is to serve all pages without https. So, to solve this we have 2 options:

1.- Login as Administrator in Prestashop and enable "SSL" and enable "SSL on all pages" options. Both are under Configure -> Shop Parameters -> General.

2.- Change your rewrite rules in your HTTP Server (nginx, apache, lighttpd, ...)

 

Link to comment
Share on other sites

  • 2 years later...
On 2/25/2017 at 3:00 PM, El Patron said:

a real common mistake is back office-->prefererences-->seo & urls-->domain and domain ssl

 

if you have domain or ssl domain with trailing slash,  www.prestaheroes.com/  this can lead to to many redirects issue.  

 

hope this tip helps someone

hi do you put https in the domain itself?

I have it as the following and I keep getting the "Too many redirects error"

 

Screenshot 2019-06-02 at 01.20.29.png

Link to comment
Share on other sites

  • 3 months later...
  • 5 months later...

Hi Guys,

There is another point which is not mentioned here. Maybe someone can face with it.

If you, have a SSL on your server side and redirect, also use a CDN like CloudFlare (it has also SSL and redirect), you can fell down in too many redirect problem. Basicly, disable it one of them or make configuration rightly.

Be sure that you redirect your HTTP site to SSL just on one side (it is enough).

  • Thanks 1
Link to comment
Share on other sites

  • 2 years later...
  • 1 year later...
On 8/5/2016 at 7:41 AM, chipiron said:

I was finally able to solve my problem by:

 

1) setting the new shop address in the SEO & URL module

2) setting the right home path (this was wrong) in the SEO & URL module

3) remove the .htaccess file from the host home directory

 

Thanks anyway!

Hi! im having the same issue, i clone the site in a subdirectory, how did you change the SEO and URL module? within the folder or in database?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...