mysqli_connect() – function php mysql db connect

Rate this post

The mysqli_connect() function opens a new connection to the MySQL server.

Syntax:

mysqli_connect(host,username,password,dbname,port,socket);

Parameter Description
host Specifies a host name or an IP address
username Specifies the MySQL username
password Specifies the MySQL password
dbname Optional. Specifies the default database to be used
port Optional. Specifies the port number to attempt to connect to the MySQL server
socket Optional. Specifies the socket or named pipe to be used
For any query or issue, feel free to discuss on http://discuss.eduguru.in

Leave a Reply

%d bloggers like this: