I make an API request with PHP and the $data
variable that comes back looks like the following:
[{
"Id": 1,
"Name": "AFC"
}, {
"Id": 3,
"Name": "RFC"
}, {
"Id": 4,
"Name": "CFC"
}, {
"Id": 5,
"Name": "LFC"
}, {
"Id": 7,
"Name": "MUFC"
}]
I want to know, how do I use a foreach loop to display a list of the titles?