I've created two new tables that I've added into my vbulletin database.
But can someone possibly explain how you access and query other (non-vb) databases, to run queries, and then be able to add the results of those queries into your vbulletin database?
I done the below, but I'm not sure how to return back to the vbulletin database.
PHP Code:
if(!empty($dbname) && !empty($tname))
{
//Submitted Valid data, need to check if DataBase and Table exists
$checkdb = mysql_select_db($dbname);
if(!$checkdb)
{
$error = 'Error!! That Database does not exist. <br/><br/>Please go back and input a correct database and table name.';
print_cp_message($error);
} else {
//Database Exists, Check to see The Table Exists..TO DO
//Ok, Its a new item Database and Table, so add it
$query = $db->query_read("INSERT INTO " . TABLE_PREFIX . "multi_db_add (db_name, table_name) VALUES ('{$dbname}', '{$tname}') ");
print_cp_message('Database and Table added Successfully', 'multiuser.php?do=modify',1);
}
}