By default you can not connect to remote MySQL server remotely for security reasons. To enable this feature do the following steps:
1) edit /etc/my.cnf file
2) Comment or remove "skip-networking" command
3) Add "bind-address=SERVER-IP-ADDRESS" to this file
4) Restart mysql service to apply above changes
5) Grant access to a database for a remote IP and user with the following command:
GRANT ALL ON DATABASE_NAME.* TO USERNAME@'REMOTE_IP' IDENTIFIED BY 'PASSWORD'
Now the remote user should access to the specified database remotely. Note that you need to open port 3306 tcp for remote access on the server machine. If you are using linux iptables you can use the following command:
iptables -A INPUT -i eth0 -p tcp --destination-port 3306 -j ACCEPT
To read more about this subject visit the following pages: