1from selenium import webdriver
2import webbrowser
3
4driver = webdriver.Chrome()
5driver.get("example.com")
6button = driver.find_element_by_id('idofbutton')
7button.click()
1from selenium import webdriver
2
3driver = webdriver.Firefox()
4# Go to your page url
5driver.get('your page url')
6# Get button you are going to click by its id ( also you could us find_element_by_css_selector to get element by css selector)
7button_element = driver.find_element_by_id('button id')
8button_element.click()
9