Fixed click and added opas profile

This commit is contained in:
Eljakim Herrewijnen 2021-12-31 10:18:27 +01:00
parent 2f0a41962e
commit 17855de0bd
2 changed files with 10443 additions and 2 deletions

File diff suppressed because it is too large Load Diff

View File

@ -36,7 +36,9 @@ else:
else: else:
print("Its a weekday") print("Its a weekday")
driver = webdriver.Firefox(executable_path="./geckodriver") fp = webdriver.FirefoxProfile("/home/opa/.mozilla/firefox/sib3verx.default-release")
driver = webdriver.Firefox(fp,executable_path="./geckodriver")
def PlayMe(): def PlayMe():
if(sunday): if(sunday):
driver.get(spijkenissee_omroep_url) driver.get(spijkenissee_omroep_url)
@ -48,7 +50,8 @@ def PlayMe():
else: else:
driver.get(refomroep_stream) driver.get(refomroep_stream)
time.sleep(2) time.sleep(2)
button = driver.find_element_by_xpath('/html/body/div/section/div[3]/button')#('//html//body//div//main//section//div[1]//div//iframe')
button = driver.find_element_by_xpath('/html/body/div/div/section/div[3]/button')#'/html/body/div/section/div[3]/button')#('//html//body//div//main//section//div[1]//div//iframe')
#/html/body/div/main/section/div[1]/d #/html/body/div/main/section/div[1]/d
button.location[0] = 10 button.location[0] = 10
print(button.location) print(button.location)