هذا الخطاء يظهر لى ولا افهم ما السبب فيه
Warning: mysqli_query() expects parameter 1 to be mysqli, null given in C:\wamp\www\db\db.php on line 21
وهذا هو الموجود فى الملف
<?php
$host = "localhost";
$UserName = "root";
$password = "";
$dbname = "hp";
$connection = @mysqli_connect($host,$UserName,$password, $dbname);
if (!$connection)
{
die('error connecting to database server'.mysql_error());
}else{
print "Success";
}
$query = "SELECT * FROM tableone";
$result = mysqli_query($cxn,$query)
or die ("Couldn’t execute query.");
?>هل من مساعد فى الموضوع دا؟
