I have details stored in a database of a web site firstweb.com

I have created another web site secondweb.com

I want to use data from database of firstweb.com

Is this possible ...

Assume : I have all user id and password for both these databases


If YES, how to do this

Please help

Recommended Answers

All 4 Replies

If you have two separate databases what is the problem ?

I tried

$con = mysql_connect("secondweb.com:3306","user","password") or die("Database ERROR ");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}

Gives error

i will like to bring to your notice that
many web hosting companies do not allow database connectrion across the web site
and some allows

hence before booking a web space ahve clear idea about this

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.