0

On web-page there is button, which describe by code below:

<button onclick="getListRating(1); return false;" class="button is-gray pagination__more">Open</button>

Need to click by use selenium lib - first i tried to find as "css_celector" but it didn't work:

allm=driver.find_element(By.CSS_SELECTOR, 'button is-gray pagination__more')  # Find button
allm.click() # Click!

What find class i need to use to click this button?

1
  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Commented Oct 21, 2021 at 9:39

1 Answer 1

1

I'd find the button by the onclick attr. Here is a solution with xpath.

button = driver.find_element_by_xpath('//button[@onclick="getListRating(1); return false;"]')
button.click()
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.