Conenct to a database from another server

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
artfhc
Forum Newbie
Posts: 23
Joined: Sun May 23, 2004 11:38 pm
Contact:

Conenct to a database from another server

Post by artfhc »

Say my code is in abc.com, but the mysql db is actually located in mysql.def.com. I was trying to connect using mysql_connection(...), but I got these warning messages:

Code: Select all

Warning: MySQL Connection Failed: Access denied for user: 'def@xxx.xxx.xxx.xxx' (Using password: YES) in /home/virtual/site442/fst/var/www/html/login/login.php on line 5
and line 5 is where I use mysql_connection. Please help me. Thankyou so much.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

the remote database has to be set up correctly to allow/accept remote database connections and queries.. which is quite dangerous and most hosts will not allow it.
Post Reply