- Code: Select all
// redirect support
if ((in_array($browser->getResponseCode(), array(301, 307)) && in_array($method, array('GET', 'HEAD'))) || in_array($browser->getResponseCode(), array(302,303)))
$this->call($browser->getResponseHeader('Location'), 'GET', array(), $headers);
why there is immediate redirects when curl have settings for this?
why `override` CURLOPT_FOLLOWLOCATION and CURLOPT_MAXREDIRS?
i mean, when i set up this two to false and 1 i expect my browser class will not be redirected, but it still does.
i understand that code above and curl params above are different things but they are connected in some way
can somene explain this to me, please?
maybe better add settings which will duplicate above params for class and some constant which will define to use default settings or not?
or maybe someone used `no-redirects` mode in some other way?