I would like to know what is the best way of generating page titles in Laravel please.
I understand how to do it in pure PHP but with Laravel I am a bit lost.
For example, you have a main layout file, inside the layout file you have partials, if a partial shows content "XYZ" and that in this content I have already a field "title", how can I pass this $data->title that may come from multiple controllers to the main layout file, this is the part that confuses me.
Best way to generate page titles?
Hello,
I would like to know what is the best way of generating page titles in Laravel please. I understand how to do it in pure PHP but with Laravel I am a bit lost.
For example, you have a main layout file, inside the layout file you have partials, if a partial shows content "XYZ" and that in this content I have already a field "title", how can I pass this $data->title that may come from multiple controllers to the main layout file, this is the part that confuses me.
I hope I explain it correctly:-)
Thanks!