mysqli_connect(): (HY000/2002): Can't connect to local MySQL server through socket

前端 未结 1 961
陌清茗
陌清茗 2021-01-19 14:30

I need help bad...I got this error trying to display a database using php:

mysqli_connect(): (HY000/2002): Can\'t connect to local MySQL server thro

相关标签:
1条回答
  • 2021-01-19 14:56

    JUST FOUND A SOLUTION!

    I just replaced localhost with 127.0.0.1.

    Oddly enough, I think I've tried this before. Maybe messing around with the config and retrying it got it working now.

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