title: PDO Class is not working returns a blank page when I try to run it?
body: <p>I've created an email class that will add users to a mysql database.
  then I've created  two methods, the first is private static so I can access it within the second method which is public static, when run this class displays a blank page?
  What could be the cause of the blank page?</p>
  
  <pre><code>class Email {
  private static function DATABASE() {
      $dbh = new PDO("mysql:host=localhost;dbname=emails", 'bjw123nasd4441', 'hj12j2kJKj11s');
      return $dbh;
  }
  public static function addemail($email) {
      $sqldata = array('email' =&gt; $email);
          $stat = Email::DATABASE();
      $stat-&gt;prepare("INSERT INTO tasklist (email) VALUES (:email)");
      $stat-&gt;execute($sqldata);
      }
  }
  
  Email::addemail('foo@bar.com');
  </code></pre>
  
  <p>I get this error with PHP Display Errors..</p>
  
  <p>Call to undefined method PDO::execute()</p>