Looking at connecting to the MySQL db ....
From an existing script (in the bb system) I see it's done by the code I've copied below.
Can someone please explain what this does? How it works?
I'm quite familiar with SQL, but not so much with PHP.
There is also a mySQL.PHP file, which does a connect, and that shows the connection to be user="root" and password=" ".
BUT .... in the db admin, it shows I have three users registered (xxxx_ibrd1 etc.), none of whome is "root".????
Now getting totally confused! ............
Can anyone explain how this fits together please?
//--------------------------------
// Load the DB driver and such
//--------------------------------
$INFO['sql_driver'] = !$INFO['sql_driver'] ? 'mySQL' : $INFO['sql_driver'];
$to_require = ROOT_PATH."sources/Drivers/".$INFO['sql_driver'].".php";
require ($to_require);
$DB = new db_driver;
$DB->obj['sql_database'] = $INFO['sql_database'];
$DB->obj['sql_user'] = $INFO['sql_user'];
$DB->obj['sql_pass'] = $INFO['sql_pass'];
$DB->obj['sql_host'] = $INFO['sql_host'];
$DB->obj['sql_tbl_prefix'] = $INFO['sql_tbl_prefix'];
$DB->obj['debug'] = ($INFO['sql_debug'] == 1) ? $_GET['debug'] : 0;
// Get a DB connection
$DB->connect();