我知道在 php 脚本中:
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
将遵循重定向。有没有办法使用命令行 cURL 跟踪重定向?
使用位置标头标志:
curl -L <URL> curl --location <URL> # or (same thing)