Good Afternoon,
I have a controller that returns a view and model
$content = Content::find([‘page’ => ‘/site/index’])->all();
In the view i would like to display in different places the content of $content
So the table has these fields:
ID => 1
Page => Index
Region => region1
Data => testdata
I want to in the view use the data value where region = region1
then use the data value where region = region2
ideally i didn’t want to have to build multiple queries for each region hence trying to extract the data from the model.