http-client
時會自動跟隨重定向,我這里想手動處理重定向.Location
來完成Request
中 guardMax
函數(shù)似乎在超出次數(shù)之后只會拋出異常allow_redirects
配置,結(jié)果會是超出 max
后直接拋出異常而不會繼續(xù)處理請求操作系統(tǒng): Windows
Workerman版本: 5.0
http-client: 2.2
$http -> request('https://example.com/', [
'method' => 'POST',
'version' => '1.1',
'allow_redirects' => [
'max' => 1
],
// --snip--
]);