PDO: Could not find driver php/mysql

前端 未结 2 768
南笙
南笙 2020-12-10 18:50

i\'m having issues connecting to my database on a web host that I have, i\'m using the following:

$dsn = \'mysql:host=mysql1.hosting.digiweb.ie;dbname=mydbna         


        
2条回答
  •  眼角桃花
    2020-12-10 19:21

    Change your extension dir to be absolute in php.ini. I changed it from

    extension_dir = "ext" 
    

    to

    extension_dir = "C:/{PATH TO PHP DIRECTORY}/ext"
    

    and it worked.

提交回复
热议问题