I am using this loop to bring more than one row from a table:
while ($stmt->fetch()) {
$holidays[]= ['holid_date'=>$holid_date,'holid_name'=>$name];
}
the problem with the above is that it creates a multi-dimensional array…the key names represent table cols.
Can the multidimensional array be avoided…is it possible?By altering the syntax.
I just want it to look like a non-multidimensional/associative array…parkinT 's code is the solution…I just want to do something more before closing the topic
That is great to hear.
Thanks for making an old man feel good. As I said, it has been quite a long time since I did anything serious with PHP. My memory is not quite as bad as I thought!