Php fails to use the mysql extension library to connect to the mysql server. When php uses the mysql extension library to expand to the mysql server, errors always occur. It is said that the page cannot be opened, and no detailed error is reported. if I try it, other errors will be reported! The configuration is also made in the php. ini & nbsp; file. An error occurred while using php_info () to connect to the mysql server using the mysql extension Library.
An error always occurs when php uses the mysql extension library to expand the connection to the mysql server. It is said that the page cannot be opened, and no detailed error is reported. if I try it, other errors will be reported! The php. ini file is also configured. You can also see Mysql on the page using the php_info () function. It is hard to understand.
The following is my database connection statement:
$ Link = mysql_connect ("localhost: 3306", "root", "123456 ");
If (! $ Link ){
Die ("error message is". mysql_error ());
}
It is hard to understand. I don't know why.
The following are the configurations in my php. ini file.
Extension_dir = "D:/php/ext"
Extension = php_msql.dll
Shared:
------ Solution --------------------
Extension = php_myql.dll extension open not, open the error message to see.
------ Solution --------------------
$ Con = mysql_connect ("localhost", "mysql_user", "mysql_pwd ");
If (! $ Con)
{
Die ('could not connect: '. mysql_error ());
}