Closed dijkr closed 1 year ago
The view banner_cat.antlers.html has been created and the html code is added: `
Solved by:
$category = $product->Category;
$category = Category::where('slug', $categorySlug)->first();
Both queries will get the data that both views need. They all load correctly.
The category has its own banner, but its loaded at:
Right now, these views are getting the data from the controller seperately, when loading the view. Meaning, that if the content will be modified from the CMS, it need to be done at multiple locations. To make this process straightforward, it need to be done to a partial (Antlers).