I am new on this MySQLi connection. I have system codes here and working on WAMP server localhost. I changed the old mysql connection to new mysqli connection and got rid of these "deprecated errors". But But my problem is that I could not login or access query (sql related function). What I am saying is that I got rid of deprecated errors but could not login/access my database.
//This is my OLD connection:
mysql_connect("localhost", "root", "") or die(mysql_error());
mysql_select_db("towertec_master") or die(mysql_error());
//This is my NEW connection
$link = mysqli_connect ("localhost", "root", "", "towertec_master") or die(mysql_error());
Also here is my OLD fetch connection:
$sql=mysql_query("SELECT organization_name,address,phone,email FROM system_config");
$row=mysql_fetch_assoc($sql);
$organization_name=stripslashes(trim($row['organization_name']));
$address=stripslashes(trim($row['address']));
$phone=stripslashes(trim($row['phone']));
$email=stripslashes(trim($row['email']));
NEW fetch connection:
$query = "SELECT organization_name, address, phone, email FROM system_config" or die("Error in the consult.." . mysqli_error($link));
$result = mysqli_query($link, $query);