artesaos / seotools

SEO Tools for Laravel
MIT License
3.04k stars 503 forks source link

Set the title dynamically #278

Closed MahbodHastam closed 1 year ago

MahbodHastam commented 1 year ago

How do I set the website title dynamically from the database or another config file? SeoTools::setTitle() only changes the page title

J-Brk commented 1 year ago

By integrating SeoTools::setTitle() into your application and using the generator in the blade as explained in the documentation. Closing this issue since it's not an issue with this package.

Rattone commented 9 months ago

I'm reopening this issue because I believe that the problem is in changing the "title" (e.g. site name) positioned after the separator. To change it dynamically set the "seotools.meta.defaults.title" config like this: config(['seotools.meta.defaults.title' => $siteName])