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

后端 未结 2 429
孤街浪徒
孤街浪徒 2021-01-07 01:21

I got these error in Codeigniter.

Fatal error: Uncaught Error: Call to undefined function mysql_pconnect() in

C:\\xampp1\\

相关标签:
2条回答
  • 2021-01-07 01:48

    Because you're using Codeigniter, you're most likely using their Database Class and drivers so you're not using PHP's MySQL functions directly.

    Therefore, all you need to do is change

    $db['default']['dbdriver'] = 'mysql';
    

    to

    $db['default']['dbdriver'] = 'mysqli';
    
    0 讨论(0)
  • 2021-01-07 02:01

    In PHP5.6 or higher versions, mysql_ functions are deprecated and totally removed. Try using mysqli_ functions.

    0 讨论(0)
提交回复
热议问题