![]() If you run into any problems, it’s likely because you didn’t put the chromedriver.exe file in a folder that has been added to your system path, so try to correct that first before doing any other troubleshooting. from selenium import webdriver driver = webdriver.Chrome() driver.get(' ') headlines = driver.find_elements_by_class_name("headline") for headline in headlines: print(()) driver.close() It should pop up a Chrome window, take you to the NASA website, and then print out the headlines from that site. ![]() ![]() Here’s some Python code that you can run to make sure that your setup is working.
0 Comments
Leave a Reply. |