Friday 3 August 2018

Website features in odoo11 | Website metadata in odoo.

This simple mixin simply allows you to easily inject metadata in your frontend pages.
class BlogPost(models.Model):
    _name = "blog.post"
    _description = "Blog Post"
    _inherit = ['website.seo.metadata', 'website.published.mixin']
This mixin adds 3 fields on your model:
  • website_meta_titleChar field that allow you to set an additional title to your page
  • website_meta_descriptionChar field that contains a short description of the page (sometimes used in search engines results)
  • website_meta_keywordsChar field that contains some keywords to help your page to be classified more precisely by search engines; the “Promote” tool will help you select lexically-related keywords easily
These fields are editable in the frontend using the “Promote” tool from the Editor toolbar. Setting these fields can help search engines to better index your pages. Note that search engines do not base their results only on these metadata; the best SEO practice should still be to get referenced by reliable sources.

1 comment: