From 8646aeda0adb21062711d8003cc8843953a1dbda Mon Sep 17 00:00:00 2001 From: houziqiang Date: Fri, 24 Feb 2017 18:41:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20list=20($key,=20$value)=20?= =?UTF-8?q?=3D=20explode(':',=20$line);=20explode=E5=88=86=E5=89=B2?= =?UTF-8?q?=E5=AD=97=E7=AC=A6=E5=AF=BC=E8=87=B4=E7=9A=84=E9=97=AE=E9=A2=98?= =?UTF-8?q?=EF=BC=8C=E6=9C=89=E4=BA=9Bheader=E6=95=B0=E6=8D=AE=EF=BC=8Ca:b?= =?UTF-8?q?,=E8=80=8C=E4=B8=8D=E6=98=AF=E4=BB=A5a:=20b=E5=88=86=E5=89=B2?= =?UTF-8?q?=E7=9A=84=E3=80=82=E6=89=80=E4=BB=A5=E5=B0=B1=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E4=BA=86=E4=B8=8B=E9=97=AE=E9=A2=98=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Curl.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Curl.php b/Curl.php index ef5f36f..980d884 100644 --- a/Curl.php +++ b/Curl.php @@ -472,8 +472,8 @@ private function _extractCurlHeaders ($response) if ($i === 0) { $headers['http_code'] = $line; } else { - list ($key, $value) = explode(': ', $line); - $headers[$key] = $value; + list ($key, $value) = explode(':', $line); + $headers[$key] = ltrim($value); } }