phpOpenTracker/phpOpenTracker/Database Driver.php,1.3,1.4
Sebastian Bergmann <[email protected]>
| Newsgroups | gmane.comp.web.phpopentracker.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/phpopencounter/phpOpenTracker/phpOpenTracker/Database
In directory sc8-pr-cvs1:/tmp/cvs-serv5432
Modified Files:
Driver.php
Log Message:
Flush.
Index: Driver.php
===================================================================
RCS file: /cvsroot/phpopencounter/phpOpenTracker/phpOpenTracker/Database/Driver.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** Driver.php 16 Dec 2003 11:08:53 -0000 1.3
--- Driver.php 16 Dec 2003 11:24:30 -0000 1.4
***************
*** 22,25 ****
--- 22,42 ----
public function __construct() {
$this->configuration = phpOpenTracker_Configuration::getConfiguration();
+ $this->connect();
+ }
+
+ public function __destruct() {
+ $this->disconnect();
+ }
+
+ public function prepareString($string) {
+ $string = substr($string, 0, 254);
+
+ if (ini_get('magic_quotes_gpc')) {
+ $string = stripslashes($string);
+ }
+
+ $string = str_replace("'", "''", $string);
+
+ return $string;
}
***************
*** 57,72 ****
}
! public function prepareString($string) {
! $string = substr($string, 0, 254);
!
! if (ini_get('magic_quotes_gpc')) {
! $string = stripslashes($string);
! }
!
! $string = str_replace("'", "''", $string);
!
! return $string;
! }
!
abstract protected function fetchRow();
abstract protected function executeQuery($query, $isManip, $limit);
--- 74,79 ----
}
! abstract protected function connect();
! abstract protected function disconnect();
abstract protected function fetchRow();
abstract protected function executeQuery($query, $isManip, $limit);
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive? Does it
help you create better code? SHARE THE LOVE, and help us help
YOU! Click Here: http://sourceforge.net/donate/