I am trying to extract specific elements from a dynamically constructed site (Namely this site). While I am not fluent in web technology, looking at the page source code it appears it is dynamically generated.
Therefore, I understood a web driver such as Selenium would be required to scrape it instead of a simple get request. (Which gets me the code generating this page instead of the actual result I view as a user)
However, it was unclear to me how exactly Selenium should be used for such a case. I saw it allows searching by class, and I saw that the smallest class containing what I required was "table table-bordered table-hover " which had a element, and under it a series of tr elements, each broken into td elements, and that I can get the file name from the button onclick action in those.
I saw that the table I required had a tag of class="table table-bordered table-hover ", so naturally I tried to look for it with:
driver.find_element(By.CLASS_NAME, 'table table-bordered table-hover ')
But I got an exception stating it was not found. Since it does exist, I assume I am misusing the find_element command. What is the right way to use it?
Note - I noticed that in this specific case, I can go to MainIO_Hok.aspx instead and get what I need, but I was wondering how I could have handled it directly from the page I was viewing.