Search
 
SCRIPT & CODE EXAMPLE
 

HTML

how to get html code in selenium python

#_*_coding: utf-8_*_
from selenium import webdriver
import time
# start web 
browserbrowser=webdriver.Firefox()
# get source 
codebrowser.get("https://en.wikipedia.org")
html = browser.page_source
time.sleep(2)
print(html)
# close web browser
browser.close()
Comment

get html selenium python

from selenium import webdriver

browser = webdriver.Firefox()
browser.get("http://example.com")

html_source = browser.page_source
if "whatever" in html_source:
    # do something
else:
    # do something else
Comment

PREVIOUS NEXT
Code Example
Html :: input disable autocomplete 
Html :: line break 
Html :: html add image 
Html :: svg icon not showing html 
Html :: bootstrap 4 success alert 
Html :: html table two headers 
Html :: difference between first of type and first child 
Html :: change text direction in html 
Html :: javascript remove the current tr with click 
Html :: html table filter by all columns 
Html :: html tab character tag 
Html :: v-select key 
Html :: How to make Website Metadata 
Html :: on this image error 
Html :: html tag for modal 
Html :: tailwind css dropdown 
Html :: inner text and inner html 
Html :: javascript button href html 
Html :: html theme color 
Html :: html image 
Html :: hide first option in select 
Html :: alpine js click preventdefault 
Html :: HTML Image Maps 
Html :: how to make an image link on html 
Html :: time input html 
Html :: video player html 
Html :: bootsrap main section fill all height with navbar 
Html :: how to add preloader in html page 
Html :: html faq 
Html :: how to create button in html 
ADD CONTENT
Topic
Content
Source link
Name
5+8 =