SqlHelper::__construct PHP Method

__construct() public method

public __construct ( )
public function __construct(){

$this->conn=mysql_connect($this->host,$this->username,$this->password);
if(!$this->conn){
die("连接失败".mysql_error());
}
mysql_select_db($this->dbname,$this->conn);
}

Usage Example

Example #1
0
 public function __construct()
 {
     parent::__construct('replaycomment');
 }
All Usage Examples Of SqlHelper::__construct