title: Selenium Webdriver - unable to click on button
body: <p>HTML code:</p>
  
  <pre><code>&lt;div class="buttonBG"&gt;  
  &lt;input type="button" onclick="window.location.href='?mod=eA&amp;amp;act=00001';"        class="buttonGreen" value="TK"&gt;         
  &lt;input type="button" onclick="ttoggle('carianDiv');" class="buttonGreen"   value="CK"&gt; 
  &lt;/div&gt; 
  </code></pre>
  
  <p>Below is my java code, when I try with below code. Can I know whats wrong is in my selenium webdriver code:</p>
  
  <pre><code>driver.findElement(By.xpath("//input[@class='buttonGreen' and  contains(@onclick, 'window.location.href='?mod=eA&amp;act=00001')]")).click();
  </code></pre>