loading.........
Sorry ya vi lo que es... en su método Query, lo reemplazan por su el prefix de sus tablas.
Código PHP:
/**
* Query
* This function will run a query against the database and return the result of the query.
*
* @param String $query The query to run.
*
* @see LogQuery
* @see SetError
*
* @return Mixed Returns false if the query is empty or if there is no result. Otherwise returns the result of the query.
*/
function Query($query='')
{
// if we're retrying a query, we have to kill the old connection and grab it again.
// if we don't, we get a cached connection which won't work.
if ($this->_retry) {
$this->Connect();
}
// Trim query
$query = trim($query);
if (!$query) {
$this->_retry = false;
$this->SetError('Query passed in is empty');
return false;
}
if (!$this->connection) {
$this->_retry = false;
$this->SetError('No valid connection');
return false;
}
if ($this->TablePrefix !== null) {
$query = str_replace("[|PREFIX|]", $this->TablePrefix, $query);
} else {
$query = str_replace("[|PREFIX|]", '', $query);
}
$this->NumQueries++;
if ($this->TimeLog !== null || $this->StoreQueryList == true) {
$timestart = $this->GetTime();
}
if (!$this->_unbuffered_query) {
$result = mysql_query($query, $this->connection);
} else {
$result = mysql_unbuffered_query($query, $this->connection);
$this->_unbuffered_query = false;
}
if ($this->TimeLog !== null) {
$timeend = $this->GetTime();
$this->TimeQuery($query, $timestart, $timeend);
}
if($this->StoreQueryList) {
if(!isset($timeend)) {
$timeend = $this->GetTime();
}
$this->QueryList[] = array(
"Query" => $query,
"ExecutionTime" => $timeend-$timestart
);
}
if ($this->QueryLog !== null) {
if ($this->_retry) {
$this->LogQuery("*** Retry *** Result type: " . gettype($result) . "; value: " . $result . "\t" . $query);
} else {
$this->LogQuery("Result type: " . gettype($result) . "; value: " . $result . "\t" . $query);
}
}
if (!$result) {
$error = mysql_error($this->connection);
$errno = mysql_errno($this->connection);
if ($this->ErrorLog !== null) {
$this->LogError($query, $error);
}
$this->SetError($error, E_USER_ERROR, $query);
// we've already retried? don't try again.
// or if the error is not '2006', then don't bother going any further.
if ($this->_retry || $errno !== 2006) {
$this->_retry = false;
return false;
}
// error 2006 is 'server has gone away'
// http://dev.mysql.com/doc/refman/5.0/en/error-messages-client.html
if ($errno === 2006) {
$this->_retry = true;
return $this->Query($query);
}
}
// make sure we set the 'retry' flag back to false if we are returning a result set.
$this->_retry = false;
return $result;
}
please cierren el post :p
connection closed.