Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
ZomatoSearchPage
# Set Webdriver
driver = webdriver.Chrome(chromepath)
out_lst = []
# Loop Through Search Pages that we wanted
for i in range(1, 1003):
print('Opening Search Pages ' + str(i))
driver.get('https://www.zomato.com/jakarta/restoran?page={}'.format(i))
print('Accessing Webpage OK \n')
url_elt = driver.find_elements_by_class_name("result-title")
# Loop Through Lists of Web Elements
for j in url_elt:
url = j.get_attribute("href")
out_lst.append(url)
driver.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.