Some days ago I noticed a redirect loop on a Magento installation I'm working on.

The issue is visible when ordering products in the front end, I can't say when it started.

You can take a look at the problem here: https://www.kirpalani.com/en/sale

If you order by any option you get stuck in an infinite redirect loop, for example, price: https://www.kirpalani.com/en/sale?dir=asc&order=price

I tried anything I could think of, including:

clear magento cache clear browser cache clear cookies reindex rewrite rules reset files permissions checking db for corrupted tables restoring db from a backup ... I'm stuck on this issue for 4 days now and I don't have any other idea how to solve this. Any thought? Is there something trivial I'm missing?

PHP logs are clear, I'm running PHP 5.5 FPM with nginx on centos 7.

  2. Blog post : permission issue
  3. Magento sort Categories & subcategory by Name when Display on Site ( multiple language site )

Thanks in advance.

  • 1
    it looks like for one query it works fine but for more than one query it redirect recursively. Oct 29, 2016 at 16:01
  • I have this exact problem! When sorting on a category page the page just redirects forever, but only if two get variables are present. How did you fix it?
    – user49519
    Feb 28, 2017 at 16:48

1 Answer 1


I had this issue on Magento and only just discovered it.

It turns out this bug was introduced with the 8788 Patch but only seems to affect some builds.

To resolve go to file: app/code/core/Mage/Core/Helper/Url.php

On line 54:


return $this->escapeUrl($url);


return $url;

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.