Issue
I am trying to import the world population figure from website 'https://countrymeters.info/en', but unable to import the same by using Python
Thank & much appreciated for help! Below screenshot of my code
Solution
the main page fetches it first but https://countrymeters.info/en/World#Population_clock doesn't. I got this to work:
res = requests.get("https://countrymeters.info/en/World#Population_clock").text
res = res.split('"cp1">')[1]
res = res.split("<")[0]
print(res)
Answered By - chax
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.