browser = webdriver.Chrome(executable_path="C:\Program Files (x86)\Google\Chrome\Application/chromedriver.exe") #无界面模式 def ChromeDriverNOBrowser(): chrome_options = Options() chrome_options.add_argument('--headless') chrome_options.add_argument('--disable-gpu') driverChrome = webdriver.Chrome(executable_path="C:\Program Files (x86)\Google\Chrome\Application/chromedriver.exe",chrome_options=chrome_options) return driverChrome #有界面模式 def ChromeDriverBrowser(): driverChrome = webdriver.Chrome(executable_path="C:\Program Files (x86)\Google\Chrome\Application/chromedriver.exe") return driverChrome
- THE END -
最后修改:2021年4月25日
非特殊说明,本博所有文章均为博主原创。