“require_channel: https” causes Error 310, Too Many Redirects

后端 未结 1 723
孤独总比滥情好
孤独总比滥情好 2021-02-10 07:09

If I try and force certain areas of my site to use https I get

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

If I just us

1条回答
  •  再見小時候
    2021-02-10 07:28

    Try adding

    fastcgi_param HTTPS on;
    

    To your nginx vhost, that will help Symfony recognize that the request is a SSL request, symfony is checking against the HTTPS global variable to check if the request is SSL or not and redirect acordingly, if that variable is not set inside by the webserver on a SSL request symfony will try to redirect causing the loop :)

    More info over here.. http://blog.servergrove.com/2011/04/04/symfony2-quick-tip-generateurl-with-https-on-nginx/

    0 讨论(0)
提交回复
热议问题