Fatal error: Uncaught Error: Call to undefined function mysql_connect()

后端 未结 8 762
一向
一向 2020-11-22 10:41

I am trying to do a simple connection with XAMPP and MySQL server, but whenever I try to enter data or connect to the database, I get this error.

Fata

8条回答
  •  野性不改
    2020-11-22 11:07

    mysql_* functions have been removed in PHP 7.

    You probably have PHP 7 in XAMPP. You now have two alternatives: MySQLi and PDO.

    Additionally, here is a nice wiki page about PDO.

提交回复
热议问题