when you call global.php file, it already contains function to connect to database, and other info stored in datastore.
instead of writing your code as:
PHP Code:
<?php
include("forums/includes/config.php");
include("forums/includes/functions_bbcodeparse.php");
@mysql_pconnect($servername, $dbusername, $dbpassword);
mysql_select_db("$dbname")or die(mysql_error())
you can use:
PHP Code:
<?php
chdir('forums'); // or full path /home/account/public_html/forum
require_once('global.php');
// more codes
include_once('includes/functions_bbcodeparse.php');
?>
hope that clear it up.