http://blog.51cto.com/xcf007/images/editer/InBlock.gifclass dbstuff {
var $version = '';
function connect($dbhost, $dbuser, $dbpw, $dbname = '', $pconnect = 0, $halt = TRUE, $dbcharset2 = '') {
$func = empty($pconnect) ? 'mysql_connect' : 'mysql_pconnect';
}
function select_db($dbname) {
function fetch_array($query, $result_type = MYSQL_ASSOC) {
function fetch_first($sql) {
function result_first($sql) {
function query($sql, $type = '') {
global $debug, $discuz_starttime, $sqldebug, $sqlspenttimes;
if(defined('SYS_DEBUG') && SYS_DEBUG) {
$func = $type == 'UNBUFFERED' && @function_exists('mysql_unbuffered_query') ?
$this->querynum++;
function affected_rows() {
function error() {
function errno() {
function result($query, $row = 0) {
function num_rows($query) {
function num_fields($query) {
function free_result($query) {
function insert_id() {
function fetch_row($query) {
function fetch_fields($query) {
function version() {
function close() {
function halt($message = '', $sql = '') {
|