hello everyone i am printing array from the database in the following format
Array ( [0] => 14
[task_id] => 14
[1] => 123
[user_id] => 123
[2] => 456
[employee_id] => 456
[3] => 2
[service_id] => 2
[4] => 2:00 AM
[starttime] => 2:00 AM
[5] => 4:00 AM
[endtime] => 4:00 AM
[6] => se a
[servicename] => se a
[7] => ddsdsd
[servicedescription] => ddsdsd
[8] => dsd
[employeename] => dsd
[9] => pictures/noimage.gif
[employeepicture] => pictures/noimage.gif
[10] => pictures/noimage.gif
[pic_path] => pictures/noimage.gif )
It is the result of
$rd = $this->executeQuery();
$recordsArray = array();
while (($row = mysqli_fetch_array($rd)) ){
$recordsArray[] = $row;
problem is how can i pick the single record from it like this
echo $row[$task_id]; // not working
Thanks
You need quotes around the key for this to work:
Good-luck!