I currently have both a game and a forum in the same database. It is all setup well and connected properly. But I want to use another database server for my game and clear up some database use on that one database.
I have plugins I made that create global_start vars that link the game info and the forum info and allow the login to the game from the forums and independently.
example of what I am currently using.. pulling from current database.
PHP Code:
$myvar = $vbulletin->db->query_first("
SELECT *
FROM my_game
WHERE `user` = '" . $vbulletin->userinfo['username'] . "'
LIMIT 1
");
vB_Template::preRegister('block_template', array('myvar' => $myvar));
I am just wondering how I would do this in a plug-in to connect to a completely different database server and still keep it clean with the code.