I am trying to scrape the data from the local market website (www.olx.ba), more specifically http://ift.tt/1PsEM8y, but I can't find a solution to a simple problem and I would like to ask for instructions on what to do or what to try or where to look at, or explanation what could be a problem. So far I have been using requests library, but since I am a beginner with python, I am completely fine, if someone shows how to do it with urllib or some other. So far, this is my code:
import requests
user_agent = {'User-agent': 'Mozilla/5.0'}
url = "http://ift.tt/1PsEM8y"
r = requests.get(url, user_agent)
r.text
My aim is just to get raw data, which I can format later.
Aucun commentaire:
Enregistrer un commentaire