diff --git a/b2calendar.php b/b2calendar.php index 7ccdf43368..6c603ff0d7 100644 --- a/b2calendar.php +++ b/b2calendar.php @@ -55,7 +55,6 @@ require('b2config.php'); require_once($abspath.$b2inc.'/b2template.functions.php'); require_once($abspath.$b2inc.'/b2functions.php'); require_once($abspath.$b2inc.'/b2vars.php'); -require_once($curpath.$b2inc.'/wp-db.php'); if (isset($calendar) && ($calendar != '')) { $thisyear = substr($calendar,0,4); diff --git a/b2config.php b/b2config.php index 8af4225b08..917099207f 100644 --- a/b2config.php +++ b/b2config.php @@ -49,6 +49,9 @@ $tableusers = 'b2users'; $tablesettings = 'b2settings'; $tablecategories = 'b2categories'; $tablecomments = 'b2comments'; +// tables for link manager +$tablelinks = "b2links"; +$tablelinkcategories = "b2linkcategories"; // ** Post preview function ** @@ -315,11 +318,11 @@ $HTTP_HOST = getenv('HTTP_HOST'); /* domain name */ $REMOTE_ADDR = getenv('REMOTE_ADDR'); /* visitor's IP */ $HTTP_USER_AGENT = getenv('HTTP_USER_AGENT'); /* visitor's browser */ -$server = $dbhost; -$loginsql = $dbusername; -$passsql = $dbpassword; +$server = DB_HOST; +$loginsql = DB_USER; +$passsql = DB_PASSWORD; $path = $siteurl; -$base = $dbname; +$base = DB_NAME; // This should get us the relative path of WordPress and the absolute path on the server. Yipee! @@ -331,4 +334,5 @@ for ($i = 3; $i < count($url); $i++) { $abspath = getenv('DOCUMENT_ROOT') . $relpath . '/'; $b2inc = "/$b2inc"; $pathserver = &$siteurl; +require_once($abspath.$b2inc.'/wp-db.php'); ?> diff --git a/blog.header.php b/blog.header.php index 19a60eddf9..3f8fc61c20 100644 --- a/blog.header.php +++ b/blog.header.php @@ -12,7 +12,6 @@ require_once ($curpath.$b2inc.'/b2vars.php'); require_once ($curpath.$b2inc.'/b2functions.php'); require_once ($curpath.$b2inc.'/xmlrpc.inc'); require_once ($curpath.$b2inc.'/xmlrpcs.inc'); -require_once ($curpath.$b2inc.'/wp-db.php'); $b2varstoreset = array('m','p','posts','w','c', 'cat','withcomments','s','search','exact', 'sentence','poststart','postend','preview','debug', 'calendar','page','paged','more','tb', 'pb','author','order','orderby'); diff --git a/wp-admin/b2header.php b/wp-admin/b2header.php index 7560d960cb..da9b7d7389 100644 --- a/wp-admin/b2header.php +++ b/wp-admin/b2header.php @@ -7,7 +7,6 @@ require_once($abspath.$b2inc.'/b2vars.php'); require_once($abspath.$b2inc.'/b2functions.php'); require_once($abspath.$b2inc.'/xmlrpc.inc'); require_once($abspath.$b2inc.'/xmlrpcs.inc'); -require_once($abspath.$b2inc.'/wp-db.php'); if (!isset($use_cache)) $use_cache=1; if (!isset($blogID)) $blog_ID=1; diff --git a/wp-admin/b2verifauth.php b/wp-admin/b2verifauth.php index 61961536af..f8ba6e677e 100644 --- a/wp-admin/b2verifauth.php +++ b/wp-admin/b2verifauth.php @@ -1,7 +1,6 @@