Zeile 83 | Zeile 83 |
---|
* @param boolean 1 if persistent connection, 0 if not. * @return resource The database connection resource. */
|
* @param boolean 1 if persistent connection, 0 if not. * @return resource The database connection resource. */
|
function connect($hostname="localhost", $username="root", $password="", $pconnect=0)
| function connect($hostname="localhost", $username="root", $password="", $pconnect=0, $newlink=false)
|
{ $this->link = @mysqli_connect($hostname, $username, $password) or $this->dberror(); return $this->link;
| { $this->link = @mysqli_connect($hostname, $username, $password) or $this->dberror(); return $this->link;
|
Zeile 278 | Zeile 278 |
---|
*/ function errno() {
|
*/ function errno() {
|
//return mysqli_errno($this->link);
| if(!$this->link) { return mysqli_connect_errno(); } else { return mysqli_errno($this->link); }
|
}
/**
| }
/**
|
Zeile 288 | Zeile 295 |
---|
*/ function error() {
|
*/ function error() {
|
return mysqli_error($this->link);
| if (!$this->link) { return mysqli_connect_error(); } else { return mysqli_error($this->link); }
|
}
/**
| }
/**
|
Zeile 377 | Zeile 391 |
---|
*/ function field_exists($field, $table) {
|
*/ function field_exists($field, $table) {
|
global $db;
| |
$err = $this->error_reporting; $this->error_reporting = 0; $query = $this->query("SHOW COLUMNS FROM $table LIKE '$field'");
| $err = $this->error_reporting; $this->error_reporting = 0; $query = $this->query("SHOW COLUMNS FROM $table LIKE '$field'");
|