To locate and `click()` on the element with text as **Sign up for free »** you have to induce _WebDriverWait_ for the _element to be clickable_ and you can use either of the following [Locator Strategies](https://stackoverflow.com/questions/48369043/official-locator-strategies-for-the-webdriver/48376890#48376890):
- Using `CSS_SELECTOR`:
WebDriverWait(driver, 20).until(EC.element_to_be_clickable((By.CSS_SELECTOR, "button.ysb.js-register.ysb-highlight"))).click()
- Using `XPATH`:
WebDriverWait(driver, 20).until(EC.element_to_be_clickable((By.XPATH, "//button[@class='ysb js-register ysb-highlight' and text()='Sign up for free »']"))).click()
- **Note** : You have to add the following imports :
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
To click the button with text as **Afficher plus de biens** within this [url](https://www.seloger.com/professionnels/agences-immobilieres/paris-15eme-75/agency-61886.htm#?bd=Detail_Agenceb_ann) you have to induce _WebDriverWait_ for the _element to be clickable_ and you can use either of the following solutions:
- Using `CSS_SELECTOR`:
WebDriverWait(driver, 10).until(EC.element_to_be_clickable((By.CSS_SELECTOR, "button.b-btn.b-ghost"))).click()
- Using `XPATH`:
WebDriverWait(driver, 10).until(EC.element_to_be_clickable((By.XPATH, "//button[@class='b-btn b-ghost' and contains(., 'Afficher plus')]"))).click()
- **Note** : You have to add the following imports :
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC