Question

How to resolve ERR_TOO_MANY_REDIRECTS

  • Posted on March 18, 2014
  • seon.dsAsked by seon.ds

Hello to everyone. Sorry for my English. I’m trying to solve ERR_TOO_MANY_REDIRECTS that I get on my droplet. I have CentOS 6.5 32bit, Apache 2.2.15, PHP 5.4.26, MySQL, phpMyAdmin 4.1.9.

And there is .htacces from site directory: AddDefaultCharset UTF-8

Options +SymLinksIfOwnerMatch Options -Indexes

RewriteEngine on

RewriteCond %{HTTP_HOST} ^www.site.com$ [NC]

RewriteRule ^(.*)$ http://site.com/$1 [L,R=301]

#apache2ctl -M && sudo a2enmod expires && sudo service apache2 restart (to enable mod_expires on ubuntu) <IfModule mod_expires.c> ExpiresActive On ExpiresDefault “access 7 days” ExpiresByType image/gif “access plus 1 year” ExpiresByType image/jpeg “access plus 1 year” ExpiresByType image/png “access plus 1 year” ExpiresByType image/jpg “access plus 1 year” ExpiresByType image/x-icon “access 1 year” ExpiresByType application/x-shockwave-flash “access 1 year” ExpiresByType application/javascript “access 1 year” ExpiresByType application/x-javascript “access 1 year” ExpiresByType text/css “access 1 year” ExpiresByType text/html “access 1 year” </IfModule>

RewriteRule ^(.).tpl$ [R=404] RewriteRule ^(.).zip$ [R=404]

RewriteCond $1 !^(index.php|user_guide|uploads/.|favicon.ico|docs|favicon.png|captcha/.|application/modules/./templates|application/mod$RewriteRule ^(.)$ /index.php/$1 [L]

####################################

or

RewriteRule ^(.+)$ index.php?$1 [L]

or

RewriteRule ^(.*)$ /index.php?/$1 [L,QSA]

Who can help me ?


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Olá Estou com o mesmo erro em meu site de cifras simplificadas alguem pode me ajudar? Cifras

This comment has been deleted

You basically have a redirect rule that keeps running and therefore generating too many/infinite redirections. <br> <br>Let’s start from scratch, what do you want to accomplish with your rewrite rules?