2

I have a search field in the web page that I would like to locate and search the extension in the page and click on the first search that comes in. Below is the page snippet and HTML code.

My HTML is like this:

<input type="text" placeholder="Search for extensions" class="user-input" style="width: 370px;">

if I try to get the Xpath of the html path I get below Input Text path but I am also not been able to input any text and get below error

Element with locator 'xpath://*[@id="extensions-container"]/div/div[3]/div2/div2/div/div2/form/span2/input' not found.

Click Element    name:extensions
Input Text       xpath://*[@id="extensions-container"]/div/div[3]/div[1]/div[1]/div/div[1]/form/span[1]/input    cli 

vgdub
  • 347
  • 5
  • 15

2 Answers2

2

This should work:

Input Text    css:input[placeholder="Search for extensions"]    cli
Philip Seyfi
  • 929
  • 1
  • 10
  • 24
1

Try with this locator:

//input[@placeholder="Search for extensions"] 
Todor Minakov
  • 19,097
  • 3
  • 55
  • 60