Manage SEO meta & open graph tags for all frontend pages with ease.
This extension adds SEO functionality to TastyIgniter. It supports frontend pages, Igniter.Pages out of the box. One robust solution for all your SEO needs.
TO DO:
To install this extension, click on the Add to Site button on the marketplace item page or search for IgniterLabs.SeoManager in Admin System > Updates > Browse Extensions
This extension includes one component:
After installation all pages will now display additional tabs with SEO and Open Graph fields.
To display meta information on frontend pages, you ONLY need to place the SEO component in your theme layout head section.
---
...
'[seoTags]':
---
<!DOCTYPE html>
<html>
<head>
@component('seoTags')
</head>
To configure this Extension, go to Admin System > Settings > SEO Configuration
.
SEO fields can be attached to any TastyIgniter model with single line of code. You just need to implement SEO Action in your model class like:
public $implement = [\IgniterLabs\SeoManager\Actions\SeoModel::class];
After implementing this action to your model class, SEO Manager will extend it with SEO fields and create relation to model.
To allow SEO Tags Component to recognize page with seo model attached you must passed it to the page view. This is most often done in component onRun()
method like:
$this->page['menu'] = Menus_model::find($id); // pass menu record to page view
This extension will fire seoManager.extendSeoFields
event to allow for extensibility of the form fields.
This can be used to modify or add more SEO fields. You can listen for this event like:
Event::listen('seoManager.extendSeoFields', function ($fields) {
// modify or add more fields
return $fields; // remember to return modified fields array
});
Similar approach can be used to extend Open Graph fields with seoManager.extendOgFields event
.
This extension will fire seoManager.beforeComponentRender
event to allow for extensibility. This can be used to access page with associated SEO Tag.
Event::listen('seoManager.beforeComponentRender', function ($component, $page) {
if ($page->url == '/local/:slug') {
$component->page['seoMeta']->title = $page->controller->vars['location']->name;
}
});