Commit f39bf1de authored by litaolemo's avatar litaolemo

update

parent d915bf0a
...@@ -150,13 +150,14 @@ class Crawler_xiaohongshu(): ...@@ -150,13 +150,14 @@ class Crawler_xiaohongshu():
page_element = self.driver.find_element_by_xpath("//*").get_attribute("outerHTML") page_element = self.driver.find_element_by_xpath("//*").get_attribute("outerHTML")
print(page_element) print(page_element)
self.driver.get("https://www.xiaohongshu.com/discovery/item/5ff6c6a90000000001005806") self.driver.find_element_by_xpath("/html/body/div/div/div/div/div[2]/div[1]/div/div/div[1]/div[1]/div[1]/div/div/div/img").click()
self.driver.implicitly_wait(2) self.driver.implicitly_wait(2)
time.sleep(1) time.sleep(1)
page_element = self.driver.find_element_by_xpath("//*").get_attribute("outerHTML") page_element = self.driver.find_element_by_xpath("//*").get_attribute("outerHTML")
print(page_element) print(page_element)
cookie = self.driver.get_cookies() cookie = self.driver.get_cookies()
# #
return True
# print(self.driver.get_log("performance")) # print(self.driver.get_log("performance"))
cookie_dic={} cookie_dic={}
for k in cookie: for k in cookie:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment