Too many redirects
Permalink Browser Info Environment
I have installed the plugin, but now none of my pages load and I get an error page "The webpage at **** has resulted in too many redirects." This shows up for all pages, dashboard and site pages.
Thanks for any help.
Thanks for any help.
Type: | Discussion |
---|---|
Status: | New |
The site is still in development mode, and I currently have the plugin un-installed because other people are working on it simultaneously.
But, we are using a 'web.config' file to enable pretty-urls... which, I'm sure is where the issue is arising from ( a combination of this and your script ).
But, we are using a 'web.config' file to enable pretty-urls... which, I'm sure is where the issue is arising from ( a combination of this and your script ).
<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <defaultDocument> <files> <remove value="iisstart.htm" /> <remove value="Default.htm" /> <remove value="Default.asp" /> <remove value="default.aspx" /> <add value="index.php" /> </files> </defaultDocument> <rewrite> <rules> <rule name="Imported Rule 1" stopProcessing="true">
Viewing 15 lines of 26 lines. View entire code block.
Hmmm, never come across that kind of setup before. Is that part of IIS or something?
It's tricky to debug without actually being able to see what's going on. Could you look in the net panel in Firebug? That might tell you which redirects it's trying to perform...
Jon
It's tricky to debug without actually being able to see what's going on. Could you look in the net panel in Firebug? That might tell you which redirects it's trying to perform...
Jon
I hope you got this sorted, but for the benefit of others, I have found that if BASE_URL is not defined in your site.php file, then it will cause the too many redirects issue...
Jon
Jon
Jon,
I had this exact problem on IIS. The problem is that ISAPI with IIS sets $_SERVER['HTTPS'] to "off" rather that leave it empty. This causes infinite redirect loops since your conditional statements in jbx_force_ssl.php only check true/false.
To fix, rather than complicate the checks in jbx_force_ssl.php, I simply changed line 74 in your controller.php.
From:
To:
I hope you include this or a similar fix in future versions, and good work on this immensely useful little addon.
Jason
I had this exact problem on IIS. The problem is that ISAPI with IIS sets $_SERVER['HTTPS'] to "off" rather that leave it empty. This causes infinite redirect loops since your conditional statements in jbx_force_ssl.php only check true/false.
To fix, rather than complicate the checks in jbx_force_ssl.php, I simply changed line 74 in your controller.php.
From:
array($_SERVER['HTTPS'])
To:
array(($_SERVER['HTTPS']=="off") ? NULL : $_SERVER['HTTPS'])
I hope you include this or a similar fix in future versions, and good work on this immensely useful little addon.
Jason
The issue with IIS still exists. It's not only related to ISAPI but also occurs with FastCGI.
The current version (2.5) now needs the fix at line 90 of controller.php
Btw: Thanks for this useful free add on!
The current version (2.5) now needs the fix at line 90 of controller.php
Btw: Thanks for this useful free add on!
Also, if you have a .htaccess file, it would be useful to know whether you have adjusted that in any way...
Thanks,
Jon