Uncategorized

Xpath Tutorial Code

#please like and subscribe!!!!

import time
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.chrome.service import Service

#set location the location of the webdriver
s = Service('/usr/local/bin/chromedriver')

driver = webdriver.Chrome(service=s)
driver.get("https://corbah.com/")

footer_link = driver.find_element(by=By.XPATH, value="/html/body/div[4]/div/div/div[3]/div/nav/ul/li[1]/a/span")
print(footer_link.text)



#the_url = driver.find_element(by=By.XPATH, value="/html/body/main/div[2]/div/ul/li[5]/div/a")



#driver.quit()
#print(driver.refresh)






#driver.maximize_window()

print("Please like and subscribe")