Throughout the Goutteclient, the allow_redirects is set to false. I tend to agree with this because I use it for tests.
The issue is that in the abstract BrowserKit Client, which the Goutte client extends from, the variable followRedirects is set to true. So that forms submission automatically follows location.
abstract class Client
protected $followRedirects = true;
As a workaround, this option has to be set manually:
Hello.
Throughout the Goutte client, the
allow_redirects
is set to false. I tend to agree with this because I use it for tests.The issue is that in the abstract BrowserKit Client, which the Goutte client extends from, the variable followRedirects is set to true. So that forms submission automatically follows location.
As a workaround, this option has to be set manually:
The solution is to override the default value of
$followRedirects
from the BrowserKit Client:This change fixes inconsistency, but also introduces a BC break though.