title: WebDriver in Selenium will "cache" its selecting result?
body: <p>Using Selenium WebDriver in Sun JDK 1.6, I've a PageObject provide a method like this</p>
  
  <pre class="lang-java prettyprint-override"><code>public void function selectDate()
  {
       //The HTML Calendar element should be already opened by the caller. 
  
       //Line X
       this.driver.findElement(By.cssSelector(/*Selector Statement*/)).click();
       //Will cause the founded element disappeared.
  }
  </code></pre>
  
  <p>And I wish this method should be resuable. That means I can call it many times in a caller method:</p>
  
  <pre class="lang-java prettyprint-override"><code>public void function caller()
  {
       this.driver.findElement(By.
           cssSelector(/*Selector for showing the HTML Calendar*/)).click();
       po.selectDate();
  
       this.driver.findElement(By.
           cssSelector(/*Selector for showing the ANOTHER Calendar*/)).click();      
       po.selectDate();
  }
  </code></pre>
  
  <p>But an exception will occur</p>
  
  <pre><code>Element is not currently visible and so may not be interacted with;
  (... Stack trace...)
      at Line X
  </code></pre>
  
  <p>The stack trace show the error is cause by the line X in the <code>selectDate()</code> method.<br>
  If I only call the <code>selectDate()</code> method once, no exception will be thrown.<br></p>
  
  <p>The only one reason here I can guess is that WebDriver will "Cache" the selecting results,
  so if I select the same element using same CSS selector, it will find the old and disappeared one. Am I right ? Or there're somethings I missed ?</p>
  
  <p>Thanks.</p>