[英]Goutte / GuzzleHTTP Get the Content-Length / Size of the response body
我正在使用https://github.com/FriendsOfPHP/Goutte抓取頁面。 那里沒有問題。
我正在嘗試從客戶端響應對象獲取Content-Length
,但是看不到我該怎么做。
單擊文檔...使用$response = $client->getInternalResponse()
獲得Symfony\\Component\\BrowserKit\\Response
,它可以作為$response->getHeader('Content-Length')
使用。 :-)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.