phpDocumentor

MydbCredentials
in package
implements MydbCredentialsInterface

Tags
author

Sergei Shilko contact@sshilko.com

license

https://opensource.org/licenses/mit-license.php MIT

see
https://github.com/sshilko/php-sql-mydb

Table of Contents

Interfaces

MydbCredentialsInterface

Properties

$dbname  : string
Database credentials - database name If provided will specify the default database to be used when performing queries.
$flags  : int
Database credentials - connection flags With the parameter flags you can set different connection options MYSQLI_CLIENT_COMPRESS - Use compression protocol MYSQLI_CLIENT_SSL - Use SSL (encryption) MULTI_STATEMENT flag is not supported in PHP
$host  : string
Database credentials - hostname Can be either a host name or an IP address. Passing the null value or the string "localhost" to this parameter, the local host is assumed. When possible, pipes will be used instead of the TCP/IP protocol.
$passwd  : string
Database credentials - password If provided or null, the MySQL server will attempt to authenticate the user against those user records which have no password only. This allows one username to be used with different permissions (depending on if a password as provided or not).
$port  : int|null
Database credentials - port Specifies the port number to attempt to connect to the MySQL server.
$socket  : string|null
Database credentials - socket Specifies the socket or named pipe that should be used.
$username  : string
Database credentials - username

Methods

__construct()  : mixed
getDbname()  : string
getFlags()  : int
getHost()  : string
getPasswd()  : string
getPort()  : int|null
getSocket()  : string|null
getUsername()  : string

Properties

$passwd

Database credentials - password If provided or null, the MySQL server will attempt to authenticate the user against those user records which have no password only. This allows one username to be used with different permissions (depending on if a password as provided or not).

protected string $passwd
Tags
see
https://www.php.net/manual/en/mysqli.real-connect.php

Methods

__construct()

public __construct(string $host, string $username, string $passwd, string $dbname[, int|null $port = null ][, string|null $socket = null ][, int $flags = 0 ]) : mixed
Parameters
$host : string
$username : string
$passwd : string
$dbname : string
$port : int|null = null
$socket : string|null = null
$flags : int = 0

getSocket()

public getSocket() : string|null
Return values
string|null

        
On this page

Search results