[Python][爬蟲]requests 的編碼
rep = requests.get(url)
rep.content : bytes 型別
rep.text : unicode 型別
1.是由 requests 以 rep.encoding 自動轉換的!
2.rep.encoding 是以 Reponse Headers 的 Content-Type 決定!
rep = requests.get(url)
rep.content : bytes 型別
rep.text : unicode 型別
1.是由 requests 以 rep.encoding 自動轉換的!
2.rep.encoding 是以 Reponse Headers 的 Content-Type 決定!