I just had the same problem when installing phpmyadmin.
I'm using OSX-Panther 10.3.2,
fink installed mysql & entropy.ch php package.
I'm not sure where this happens (guessing the fink build of mysql) ..
but, in any case, php is using the default path to the mysql
socket to connect, which is for us /Private/tmp/mysql.sock
I believe, but my memory is fuzzy, that in 10.2 there was
now it is /private.
If you look in your php.ini file and change (or add?)
the line mysql.default_socket = /private/tmp/mysql.sock
(or wherever mysql is writing a socket on your host machine)
and restart apache / php , it should work.