
Sandeep.C.R - 2010-12-22 16:25:41 -
In reply to message 1 from Proxing
Hi,
Thank you for using this class,
Now, regarding your query, If you have to access data from different databases, it can be done using the _set_link function to use a different database link.
For Example;
<?php
include 'crdb.php';
// note the fourth paramenter, as it is required so that the function
// returns a new link regardless of identical parameters.
$link_1 = mysql_connect('localhost','root','',true);
$link_2 = mysql_connect('localhost','root','',true);
mysql_select_db('database_1',$link_1);
mysql_select_db('database_2',$link_2);
$cr1=new crdb($link_1);
echo $cr1->database_1_table(1)->name;
$cr1->_set_link($link_2);
echo $cr1->database_2_table(1)->name;
?>
If this is not your requirement, please let me know more details about what you are trying to accomplish.
NOTE: Please download the class file as I have made a bug fix regarding this requirement.
Thanks,
Sandeep.