python - Using selenium to click ajax button -


i'm trying understand how interact on site ajax element. i'm using selenium+phantomjs click "more" button has code:

<a class="js-cne-ajax cne-more-button cne-more-videos cne-light-button" data-ajaxurl="/genres/books.js?page=2" rel="nofollow" href="javascript:void(0)">more</a> 

i'm using this:

wait = webdriverwait(driver, 10) next_link = wait.until(ec.element_to_be_clickable((by.css_selector, "a.js-cne-ajax.cne-more-button.cne-more-videos.cne-light-button"))) next_link.click() driver.save_screenshot('screenshot.png') 

my problem element seems not clickable. can because css selector wrong or, in way, ajax pages needs different approach? can "rel=nofollow" create problems?


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

thorough guide for profiling racket code -