I am pretty new to selenium and I am trying to figure out how to simulate a onclick
this is what I see in the source code when I inspect the html source
<a href="#" onclick="document.getElementById('pN').selectedIndex = 0;document.getElementById('optionList').submit();return false"> <img src="images/ListingOptionSearch.jpg" onmouseover="this.src='images/ListingOptionSearchHover.jpg'" onmouseout="this.src='images/ListingOptionSearch.jpg'"> </a>
I tried :
driver.find_element_by_css_selector("a[onlick*=document.getElementById('pN')
.selectedIndex]").click()
but I get a InvalidSelectorException
any idea?
thanks!