@@ 240-246 (lines=7) @@ | ||
237 | } |
|
238 | ||
239 | // If there is no existing database connection then try to connect |
|
240 | if ( ! isset($this->dbh) || ! $this->dbh ) |
|
241 | { |
|
242 | $this->connect($this->dbuser, $this->dbpassword, $this->dbhost); |
|
243 | $this->select($this->dbname,$this->encoding); |
|
244 | if ( ! isset($this->dbh) || ! $this->dbh ) |
|
245 | return false; |
|
246 | } |
|
247 | ||
248 | // Perform the query via std mysql_query function.. |
|
249 | $this->result = @mysql_query($query,$this->dbh); |
@@ 251-257 (lines=7) @@ | ||
248 | ||
249 | ||
250 | // If there is no existing database connection then try to connect |
|
251 | if ( ! isset($this->dbh) || ! $this->dbh ) |
|
252 | { |
|
253 | $this->connect($this->dbuser, $this->dbpassword, $this->dbhost, $this->dbport); |
|
254 | $this->select($this->dbname,$this->encoding); |
|
255 | if ( ! isset($this->dbh) || $this->dbh->connect_errno ) |
|
256 | return false; |
|
257 | } |
|
258 | ||
259 | // Perform the query via std mysql_query function.. |
|
260 | $this->result = @$this->dbh->query($query); |