I am trying to scrape some information from this website http://www.dubaitrade.ae/ja-terminal-1
I have to go to the terminal code column and select 'General Cargo'
Here is the HTML.
<select name="terminal" id="terminal1" style="width:52%" tabindex="3">
<option value="GC">General Cargo</option>
<option value="T1" selected="selected">Terminal One</option>
<option value="T2">Terminal Two</option>
<option value="T3">Terminal Three</option></select>
I am unsure if the difficulty is because it is nested within this tag.Meaning it is some kind of form.
<form name="vesselform" id="vesselLinkFormID" method="post" action="/pmisc/vessel.do;jsessionid=1da4f04d50b1a09ff55171820810948e8430f1ad26af4f30e765658bb25b3ffa.e34NaxuKaxmOaO0OaxmKc34Sa3j0">
I have tried
Select(driver.find_element_by_xpath('//*[@id="terminal1"]')).select_by_visible_text('General Cargo')
Select(driver.find_element_by_id('terminal1')).select_by_visible_text('General Cargo')
Select(driver.find_element_by_css_selector("terminal1"))
Select(driver.find_element_by_name('terminal1')).select_by_visible_text('General Cargo')
I always get the error message unable to locate element.