Add PHP5-style constructor
[squirrelmail.git] / functions / abook_database.php
index 06eda0c64b561329f8a5b2ead7e0ae747a6a0732..68110ee67a9098939f21f717794d859567eba2b4 100644 (file)
@@ -147,10 +147,10 @@ class abook_database extends addressbook_backend {
     /* ========================== Private ======================= */
 
     /**
-     * Constructor
+     * Constructor (PHP5 style, required in some future version of PHP)
      * @param array $param address book backend options
      */
-    function abook_database($param) {
+    function __construct($param) {
         $this->sname = _("Personal Address Book");
 
         /* test if PDO or Pear DB classes are available and freak out if necessary */
@@ -206,6 +206,13 @@ class abook_database extends addressbook_backend {
         }
     }
 
+    /**
+     * Constructor (PHP4 style, kept for compatibility reasons)
+     * @param array $param address book backend options
+     */
+    function abook_database($param) {
+        return self::__construct($param);
+    }
 
     /**
      * Open the database.