Page 1 of 1

using MySQL from another site

Posted: Wed Mar 29, 2006 3:42 pm
by Smackie
Hello

I know this can be done but im not sure how.... im working on a site that allows php on it and i want to use a database on another site.. the site im using does not have a mysql on it can someone tell me how i could do this i tried using the ip address and stuff like that and all i get is
Warning: mysql_pconnect() [function.mysql-pconnect]: Can't connect to MySQL server on '192.168.1.%' (13) in /home2/data/hosted/maplerz/db.php on line 11
Couldn't connect to server.

Thank you
Smackie

Posted: Wed Mar 29, 2006 3:47 pm
by feyd
The MySQL server has to both allow external connections and the user connecting has to be allowed to connect via remote.

Posted: Wed Mar 29, 2006 3:48 pm
by Smackie
well see you can get mysql through them but you gotta pay a few bucks and why pay money for mysql when you already got one from another site free? and how would i check to see if i can connect remotely?

Posted: Wed Mar 29, 2006 3:56 pm
by feyd
it's apart of the user settings. Instead of user@localhost, it'd be user@ip or user@%