-1

I want to use Selenium to input text into a text field. This is the HTML of the input box

<input data-search-input="certification" placeholder="Full Name or Email" type="text">

The "certification" string is unique to this specific text input element, but I'm not sure how to use the data-search-input part. How can I use this with Selenium as it is not an explicit name or ID tag?

JeffC
  • 22,180
  • 5
  • 32
  • 55
Ben Hogan
  • 33
  • 2

1 Answers1

0

This xpath should work:

//*[@data-search-input="certification"]

But also look at Find element by attribute for css option as well.

DMart
  • 2,401
  • 1
  • 14
  • 19