Hello Friends,
There is some problem with my CODE.
I Want to fatch data in this format please help me to get this format.
The format is array(“a”,“b”,“c”);
Hello Friends,
There is some problem with my CODE.
I Want to fatch data in this format please help me to get this format.
The format is array(“a”,“b”,“c”);
Something like this?
require_once('./db_con.php');
$dbcon=new db;
$query="SELECTa, b, c FROM table";
$result = mysqli_query($dbcon,$query);
$data = array();
while($row= mysqli_fetch_assoc($result)){
$data[] = array("a" => $row["a"], "b" => $row["b"], "c" => $row["c"]);
}
print_r($data);
Unless you can give more details explaining the problem and the code we can’t really offer much help.