tenpastmidnight blog

Making hay while the sun shines

OSX MySQL and PHP - use 127.0.0.1 rather than localhost

Got MySQL back on my iBook (though a newer version than before, 4 is soooo much easier to install than 3.23 on OSX.) Cocoa MySQL could connect fine to 'localhost', so could ColdFusion, but PHP wouldn't, I kept getting an "can't connect to local mysql server" error. Eventually I tried using '127.0.0.1' rather than 'localhost' on the connection string, and it's started working, so if you're having the same problem, try that.
Comments:
check out yourSQL http://yoursql.ludit.it/index.html
 
Post a Comment



<< Home

This page is powered by Blogger. Isn't yours?