Created
February 22, 2021 16:21
-
-
Save rririanto/a623f66532f0b1104e6aec5664be358e to your computer and use it in GitHub Desktop.
Bypass & Scraping Websites that has CSS class names change frequently.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class_css = response.css('main[class^="D_"] ::attr(class)').getall()[12] | |
url = response.css('a[class^="%s"] ::attr(href)'% class_css).get() | |
print (url) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment