requests1 Python : Crawling : requests vs urllib.parse & request import requests import requests session = requests.Session() headers = { "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit 537.36 (KHTML, like Gecko) Chrome", "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" } url = "https://www.nature.com/search?q=gold+nanoparticle+synthesis&page=1" html = session.get(url, headers=headers).content pr.. 2020. 4. 21. 이전 1 다음