Tell me how can we connect to a MySQL database from a PHP script?

Submitted by: Muhammad
To be able to connect to a MySQL database, we must use mysql_connect() function as follows:

<!--?php $database = mysql_connect("HOST", "USER_NAME", "PASSWORD"); mysql_select_db("DATABASE_NAME",$database); ?-->
Submitted by: Muhammad

Read Online Junior Developer PHP Job Interview Questions And Answers