示例#1
0
 /**
  * 
  * @throws Exception
  */
 public function initialize()
 {
     parent::initialize();
     set_include_path(RA_LIBRARIES_PATH . "/jpgraph/");
     $host = "slack.ckjstzy6gz0p.us-west-2.rds.amazonaws.com";
     $password = "******";
     $user = "******";
     $dbname = "slack";
     $this->conn = pg_connect(sprintf('host=%s port=5432 user=%s password=%s dbname=%s', $host, $user, $password, $dbname));
     if ($this->conn === false) {
         throw new Exception(pg_last_error());
     }
 }