Possible duplicate of this
I am connecting the DB using the PDO.
$DBH = new PDO('mysql:host=localhost;dbname=name','dbusername','dbpassword');
This is not working here.
I am getting the error
SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
But whatever the connection we already done in mysql_connect thats working fine.Could you please help me on this.