PHP code example of basekit-laravel / basekit-laravel-seo
1. Go to this page and download the library: Download basekit-laravel/basekit-laravel-seo library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
basekit-laravel / basekit-laravel-seo example snippets
public function show(Article $article)
{
seo()
->title($article->title)
->description($article->excerpt)
->canonicalUrl(route('articles.show', $article));
return view('articles.show', [
'article' => $article,
]);
}
seo()
->title('About us')
->description('Learn more about our company.')
->canonicalUrl(route('about'))
->robots('index, follow')
->locale('en_US');