Oracle 5.0 Reference Manual page 2755

Table of Contents

Advertisement

Description
public string MysqlndUhConnection::getHostInformation(
mysqlnd_connection connection);
Returns a string representing the type of connection used.
Parameters
connection
Return Values
Connection description.
Examples
Example 20.347.
<?php
class proxy extends MysqlndUhConnection {
public function getHostInformation($res) {
printf("%s(%s)\n", __METHOD__, var_export(func_get_args(), true));
$ret = parent::getHostInformation($res);
printf("%s returns %s\n", __METHOD__, var_export($ret, true));
return $ret;
}
}
mysqlnd_uh_set_connection_proxy(new proxy());
$mysqli = new mysqli("localhost", "root", "", "test");
var_dump($mysqli->host_info);
?>
The above example will output:
proxy::getHostInformation(array (
0 => NULL,
))
proxy::getHostInformation returns 'Localhost via UNIX socket'
string(25) "Localhost via UNIX socket"
See Also
mysqlnd_uh_set_connection_proxy
mysqli_get_host_info
mysql_get_host_info
20.7.8.7.13.
MysqlndUhConnection::getLastInsertId
Copyright 1997-2012 the PHP Documentation Group. [2230]
MysqlndUhConnection::getLastInsertId
Returns the auto generated id used in the last query.
Description
public int MysqlndUhConnection::getLastInsertId(
mysqlnd_connection connection);
Returns the auto generated id used in the last query.
Mysqlnd user handler plugin (mysqlnd_uh)
Mysqlnd connection handle. Do not modify!
MysqlndUhConnection::getHostInformation
2735
example

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents