title: Best practices for a PDO class?
body: <p>I want to create a PDO class for handling data base connections.</p>
  
  <p>Here is what I have:</p>
  
  <pre><code>require('php/packages/store/store_db_settings.php');
  
  class store_pdo
  {
      private $DBH; // Data Base Handler
  
      function __construct() 
      {
          $DBH = new PDO(DB_DSN,DB_USER,DB_PASSWORD);
      }
  
      public function getHandler()
      {
          return $DBH;
      }
  
  }
  </code></pre>
  
  <p>I think this seems ok, however I am used to just using things like <code>mysql_query</code> and not really sure what problems I could run into in the future. So I thought the experience here could offer guidance.</p>
  
  <p>Is what I have sufficient? should I make my class Singleton, or use static functions? Is there a best practice?</p>
  
  <p>I don't want to go with this, then I after have several other classes using it, discover that I should have written it differently.</p>
  
  <p>P.S. I just noticed that the <code>best-practices</code> tag is no longer allowed... does that mean questions like this are discouraged now too?</p>