Skip to content
  • Tutorials
    • c programming
      • libraries
    • c++
    • Linux
    • Python
    • batch programming
    • Technology
  • IDE
  • Tools
selenium find button by text 1

selenium find button by text

June 17, 2022 by Anurag batra
browser.find_element_by_xpath('//button[normalize-space()="BUTTON-TEXT-HERE"]')

Here is what the above code is Doing:
1. It’s finding the element by its XPath.
2. It’s storing the element in a variable called “button”.
3. It’s clicking the element.

Categories Python Examples
Post navigation
how to print a char of element in list in pyhton
print a random word from list python
© MyEduKit - 2022 . All Rights Reserved.