File size: 832 Bytes
0004cda
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
import time

options = Options()
options.add_argument('--headless')
driver = webdriver.Chrome(options=options)
driver.get('https://www.messagehub.info/en/messages.do')

# Wait for rows
WebDriverWait(driver, 10).until(
    EC.presence_of_element_located((By.CSS_SELECTOR, '.dataRow'))
)

# Click first row
row = driver.find_element(By.CSS_SELECTOR, '.dataRow')
row.click()
print("Clicked row")

# Wait for formats pane to update
time.sleep(3)

# Dump right pane HTML
right_pane = driver.find_element(By.ID, 'artifactList')
print(right_pane.get_attribute('outerHTML'))

driver.quit()