title: Selenium and JSF 2.0
body: <p>When I a generate SelectOneMenu with JSF2.0 the the id I specified in the xhtml is attached to a generated ID from JSF. </p>
  
  <p>e.g. out of <code>my_fancy_id</code> it generates <code>j_idt9:my_fancy_id</code></p>
  
  <p>Now I want to test my page with Selenium 2 Web Driver. I try to re-find my select menu:</p>
  
  <pre><code>driver.findElement(By.id("my_fancy_id"));
  </code></pre>
  
  <p>Of course it does't find anything because the id is changed. What is the best way to find the select menu on the page? </p>