The mysqli class

(PHP 5, PHP 7)

Introduction

Represents a connection between PHP and a MySQL database.

Class synopsis

mysqli {
/* Properties */
intaffected_rows;
intconnect_errno;
stringconnect_error;
interrno;
arrayerror_list;
stringerror;
intfield_count;
stringclient_info;
intclient_version;
stringhost_info;
stringprotocol_version;
stringserver_info;
intserver_version;
stringinfo;
mixedinsert_id;
stringsqlstate;
intthread_id;
intwarning_count;
/* Methods */
public __construct ([ string $host = ini_get("mysqli.default_host") [, string $username = ini_get("mysqli.default_user") [, string $passwd = ini_get("mysqli.default_pw") [, string $dbname = "" [, int $port = ini_get("mysqli.default_port") [, string $socket = ini_get("mysqli.default_socket") ]]]]]] )
public autocommit ( bool $mode ) : bool
public begin_transaction ([ int $flags = 0 [, string $name ]] ) : bool
public change_user ( string $user , string $password , string $database ) : bool
public character_set_name ( void ) : string
public close ( void ) : bool
public commit ([ int $flags = 0 [, string $name ]] ) : bool
public connect ([ string $host = ini_get("mysqli.default_host") [, string $username = ini_get("mysqli.default_user") [, string $passwd = ini_get("mysqli.default_pw") [, string $dbname = "" [, int $port = ini_get("mysqli.default_port") [, string $socket = ini_get("mysqli.default_socket") ]]]]]] ) : void
public debug ( string $message ) : bool
public dump_debug_info ( void ) : bool
public get_charset ( void ) : object
public get_client_info ( void ) : string
public get_connection_stats ( void ) : bool
public get_server_info ( void ) : string
public get_warnings ( void ) : mysqli_warning
public init ( void ) : mysqli
public kill ( int $processid ) : bool
public more_results ( void ) : bool
public multi_query ( string $query ) : bool
public next_result ( void ) : bool
public options ( int $option , mixed $value ) : bool
public ping ( void ) : bool
public static poll ( array &$read , array &$error , array &$reject , int $sec [, int $usec = 0 ] ) : int
public prepare ( string $query ) : mysqli_stmt
public query ( string $query [, int $resultmode = MYSQLI_STORE_RESULT ] ) : mixed
public real_connect ([ string $host [, string $username [, string $passwd [, string $dbname [, int $port [, string $socket [, int $flags ]]]]]]] ) : bool
public escape_string ( string $escapestr ) : string
real_escape_string ( string $escapestr ) : string
public real_query ( string $query ) : bool
public reap_async_query ( void ) : mysqli_result
public refresh ( int $options ) : bool
public release_savepoint ( string $name ) : bool
public rollback ([ int $flags = 0 [, string $name ]] ) : bool
public rpl_query_type ( string $query ) : int
public savepoint ( string $name ) : bool
public select_db ( string $dbname ) : bool
public send_query ( string $query ) : bool
public set_charset ( string $charset ) : bool
public set_local_infile_default ( void ) : void
public set_local_infile_handler ( callable $read_func ) : bool
public ssl_set ( string $key , string $cert , string $ca , string $capath , string $cipher ) : bool
public stat ( void ) : string
public stmt_init ( void ) : mysqli_stmt
public store_result ([ int $option ] ) : mysqli_result
public thread_safe ( void ) : void
public use_result ( void ) : mysqli_result
}

Table of Contents