Pulling an outside database

SpaceshipSpaceship
SpaceshipSpaceship
NamecheapNamecheap
Watch

TeviH

Established Member
Impact
2
Hi,

I don't have any real experience designing a site to pull information off of a database and someone has asked if I can create a website for him that will pull its content from an external (diff server) database. How difficult is this? Where do I look for more information about this?

in short - help!

thanks
 
0
Close
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
You will have to change the "hostname" in the config from "localhost" to the database server that you want the data from e.g. db.abc.com or where ever the database server is located...
 
0
Close
Thanks, I thought that might be it - but don't most servers not allow outsiders to pull their databases? Even with userid and pw?
where is a good resource to learn how to use databases in designing a website? (basically, create a template that pulls all data from from a db)
 
0
Close
If the DB is on a CPanel server its easy just login to the cpanel on the DB site and add the address of the site that will pull it. Not sure what to do for other servers. :(
 
0
Close
TeviH said:
Thanks, I thought that might be it - but don't most servers not allow outsiders to pull their databases? Even with userid and pw?
where is a good resource to learn how to use databases in designing a website? (basically, create a template that pulls all data from from a db)

correct, some do not allow access from any other than a local domain. If your cleint has permission to use this database he can get them to add his domain to the list of allowed hosts
 
0
Close
if you are on a cPanel database then it is easy to add allowed hosts.

if on a non cPanel host or personal server then look for .my.cnf in your home directory, open it in a text editor and in this file you can allow external hosts to use the database.

Read the mysql reference manual for further info.

http://dev.mysql.com/doc/mysql/en/
 
0
Close
DomainEasy: white label portfolios are live. Enable yours.

We're social

Escrow.com
Spaceship
Domain Recover
CryptoExchange.com

NamePros updates

Switch between accounts
You can now stay logged in to more than one NamePros account in the same browser. Click your avatar, then "Accounts in this browser", to...
AIVikings
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back