title: Selenium Webdriver PHPUnit: Possible to wait on whole function instead of element?
body: <p>So there are lots of ways to make selenium wait such as</p>
  
  <pre><code>sleep(1); // sleeps for 1 second
  </code></pre>
  
  <p>or</p>
  
  <pre><code>while ($this-&gt;conditionIsFalse()) { sleep(500); }
  </code></pre>
  
  <p>or</p>
  
  <pre><code>waitForPageElement
  </code></pre>
  
  <p>etc... 
  These are for a specific element but is it possible to create a script so that selenium waits for each single element no matter what? Or a pageload etc...</p>
  
  <p>So basically it would work for the whole function and not just the current element that you are looking for. If you search for 50+ items on a page or multiple pages I rather have something that makes selenium wait for every pageload/element that writing after each search waitForPageElement ...</p>
  
  <p>Is such thing possible?</p>