2016-06-28 132 views

回答

1

這爲我工作的解決方案是這樣..

static function db() 
    { 
     try { 
      $db = DB::connection()->getPdo(); 
     } 
     catch (PDOException $e) { 
      self::fatal(
       "An error occurred while connecting to the database. ". 
       "The error reported by the server was: ".$e->getMessage() 
      ); 
     } 
     return $db; 
    } 

通過調用..

$db=self::db(); 

$db::PARAM_STR 

我解決了它。所有內部類&方法

相關問題