title: Python Selenium: Click a href="javascript:()"
body: <p>I am using chromedriver and I have the following webpage source:</p>
  
  <pre><code>&lt;form id="stepLinksForm" name="stepLinksForm" method="POST" target="mainFrame"&gt; 
  
    &lt;ul&gt; 
        &lt;li&gt; &lt;a href="javascript:submitLink('action_one.htm')"&gt;Action One&lt;/a&gt; &lt;/li&gt;
        &lt;li&gt; &lt;a href="javascript:submitLink('action_two.htm')"&gt;Action Two&lt;/a&gt; &lt;/li&gt;
        &lt;li&gt; &lt;a href="javascript:submitLink('action_three.htm')"&gt;Action Three&lt;/a&gt; &lt;/li&gt;
    &lt;/ul&gt;   
  
  &lt;/form&gt;
  </code></pre>
  
  <p>After clicking anyone of the href, the browser goes to a new page but the url stays the same.
  What I want to achieve is clicking the first href, i.e. <code>
  &lt;li&gt; &lt;a href="javascript:submitLink('action_one.htm')"&gt;Action One&lt;/a&gt; &lt;/li&gt;</code></p>
  
  <p>I have tried find_element_by_xpath, link_text and some other methods suggested on the Internet but none of them works.
  I really appreciate if someone could help.</p>