Deprecated: mysql_connect()

前端 未结 15 1367
醉酒成梦
醉酒成梦 2020-11-22 06:55

I am getting this warning, but the program still runs correctly.

The MySQL code is showing me a message in PHP:

Deprecated: mysql_connect(): T

15条回答
  •  别那么骄傲
    2020-11-22 07:59

    There are a few solutions to your problem.

    The way with MySQLi would be like this:

    To run database queries is also simple and nearly identical with the old way:

    Turn off all deprecated warnings including them from mysql_*:

    The Exact file and line location which needs to be replaced is "/System/Startup.php > line: 2 " error_reporting(E_All); replace with error_reporting(E_ALL ^ E_DEPRECATED);

提交回复
热议问题