hi im attempting to change my website from mysql to mysqli ive replace mysql with mysql on all the files and when i attempt to load site im gettting the following:
Warning: mysqli_select_db() expects parameter 1 to be mysqli, string given in /home/matureco/public_html/config/db_connect.php on line 6
heres code for this section
<?php
session_start();
include("config_global.php");
$conn = mysqli_connect(DBHOST,DBUSER,DBPASS) or die(mysqli_connect_error());
$dn = mysqli_select_db(DBNAME,$conn) or die(mysqli_connect_error());
$row = mysqli_fetch_array(mysqli_query("select * from settings where id = '1' "));
$site_name = trim(stripslashes($row['site_name']));
$email = trim($row['email']);
$keyword = trim(stripslashes($row['keyword']));
$description= trim(stripslashes($row['description']));
$logo = trim($row['logo']);
$copyright = trim(stripslashes($row['copyright']));
?>
then the file for connection details
<?php
define ("DBHOST","localhost");
define ("DBUSER","matureco_social");
define ("DBPASS","xxxxxx");
define ("DBNAME","matureco_social");
/*define ("DBUSER","root");
define ("DBPASS","");
define ("DBNAME","date_demo");*/
define ("DBPREFIX","");
define ("CHAR_SET","utf8");
define ("CACHEDIR","");
?>
if anyone can help with this be much appreicated