I just installed Apache2, php5 and mysql5 on win xp pro. Everything works fine, php works nicely and mysql shows up in phpinfo().
Connecting to mysql from the console works fine too, however when I try to do

<?

$link = mysql_connect('localhost','root', 'my_password');

?>

I get an error saying: Warning: mysql_connect() [function.mysql-connect]: Can't connect to MySQL server on 'localhost' (10061) in C:\Apache2\htdocs\mysql.php on line 3.

Anything wrong with my connection attempt, I use the same password I use when logging into MySql via the console??

I also tried downloading and installing the latest mysql connector files but that didn't solve it either.

Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.