[phpMP-CVS] CVS: phpMP/core/dba mysql.php,1.11,1.12 postgresql.php,1.2,1.3
Status: Pre-Alpha
Brought to you by:
heimidal
From: Cameron C. <nor...@us...> - 2003-09-25 03:43:59
|
Update of /cvsroot/phpmp/phpMP/core/dba In directory sc8-pr-cvs1:/tmp/cvs-serv8234 Modified Files: mysql.php postgresql.php Log Message: changes to mysql are some formatting things, and postgres is the begining of the sql_db function... I have no idea if it works yet... (I'm recompiling php as I write this...). Index: mysql.php =================================================================== RCS file: /cvsroot/phpmp/phpMP/core/dba/mysql.php,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -r1.11 -r1.12 *** mysql.php 17 Sep 2003 03:02:42 -0000 1.11 --- mysql.php 25 Sep 2003 03:43:54 -0000 1.12 *************** *** 35,41 **** // ! // CONSTRUCTOR - sql_connect // ! function sql_db($hostname, $username, $password, $database, $persistant) { $this->hostname = $hostname; --- 35,41 ---- // ! // CONSTRUCTOR - sql_connect // ! function sql_db($hostname, $port, $username, $password, $database, $persistant) { $this->hostname = $hostname; *************** *** 45,49 **** $this->persistant = $persistant; ! if($this->persistant == TRUE) { $this->db_connection_id = @mysql_pconnect($this->hostname, $this->username, $this->password); --- 45,49 ---- $this->persistant = $persistant; ! if( $this->persistant == TRUE) { $this->db_connection_id = @mysql_pconnect($this->hostname, $this->username, $this->password); Index: postgresql.php =================================================================== RCS file: /cvsroot/phpmp/phpMP/core/dba/postgresql.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** postgresql.php 14 Sep 2003 21:03:31 -0000 1.2 --- postgresql.php 25 Sep 2003 03:43:55 -0000 1.3 *************** *** 22,25 **** * */ ! ! ?> \ No newline at end of file --- 22,55 ---- * */ ! ! class sql_db ! { ! var $db_connection_id; ! var $db_query_result = 0; ! var $db_query_count = 0; ! var $db_row = array(); ! var $db_rowset = array(); ! ! // ! // CONSTRUCTOR - sql_connect ! // ! function sql_db($hostname, $port, $username, $password, $database, $persistant) ! { ! $this->hostname = $hostname; ! $this->port = $port; ! $this->username = $username; ! $this->password = $password; ! $this->database = $database; ! $this->persistant = $persistant; ! ! if( $this->persistant) ! { ! $this->db_connection_id = pg_pconnect("host=$this->hostname port=$this->port user=$this->username password=$this->password dbname=$this->database"); ! } ! else ! { ! $this->db_connection_id = pg_connect("host=$this->hostname port=$this->port user=$this->username password=$this->password dbname=$this->database"); ! } ! } ! } ! ?> |