11Saving the SeoMetadata in the Object
22====================================
33
4- The ``SeoMetadata `` can be saved in the object , so you can persist it into the
5- database. This option gives admins the possibility of changing the SEO data for
6- the document .
4+ The ``SeoMetadata `` can be set on your model classes , so that you can persist
5+ it into the database. This option gives admins the possibility to change the SEO
6+ data for the object .
77
8- In order to save the ``SeoMetadata `` in the object , the object should
8+ In order to save the ``SeoMetadata `` in the model , the object should
99implement the ``SeoAwareInterface ``. This requires a getter and a setter for
1010the ``SeoMetadata ``::
1111
@@ -32,8 +32,8 @@ the ``SeoMetadata``::
3232
3333.. tip ::
3434
35- If you are using PHP5.4+ you may also benefit from using the trait `` SeoAwareTrait ``
36- to plug these behavior into your model.
35+ Instead of implementing these methods yourself, you can also use the trait
36+ `` SeoAwareTrait `` to enable this behavior in your model.
3737
3838Now you can set some SEO data for this ``Page `` using the metadata::
3939
@@ -91,7 +91,7 @@ To be able to use this document, you have to enable the PHPCR persistence:
9191 bundle. See :doc: `the CoreBundle docs <../core/persistence >` for more
9292 information.
9393
94- After you've enabled PHPCR, map ``$seoMetadata `` as a child:
94+ After you have enabled PHPCR, map ``$seoMetadata `` as a child:
9595
9696.. configuration-block ::
9797
@@ -178,7 +178,7 @@ And after that, you can use the
178178Doctrine ORM
179179------------
180180
181- You can also use the Doctrine ORM with the CmfSeoBundle. You can just use the
181+ You can also use the Doctrine ORM with the CmfSeoBundle. Use the
182182``Symfony\Cmf\Bundle\SeoBundle\SeoMetadata `` class and map it as an
183183object:
184184
@@ -240,9 +240,9 @@ the ``SeoMetadata`` entity.
240240Form Type
241241---------
242242
243- The bundle also provides a special form type called `` Symfony\Cmf\Bundle\SeoBundle\Form\Type\SeoMetadataType ``
244- (use `` seo_metadata `` for Symfony versions older than 2.8). This form type can be
245- used in forms to edit the ``SeoMetadata `` object::
243+ The bundle also provides a special form type called
244+ `` Symfony\Cmf\Bundle\SeoBundle\Form\Type\SeoMetadataType ``. This form type can
245+ be used in forms to edit the ``SeoMetadata `` object::
246246
247247 use Sonata\AdminBundle\Form\FormMapper;
248248 use Symfony\Cmf\Bundle\SeoBundle\Form\Type\SeoMetadataType;
@@ -264,17 +264,9 @@ used in forms to edit the ``SeoMetadata`` object::
264264 option is set by default, otherwise you need to explicitly specify it in
265265 your ORM forms.
266266
267- Sonata Admin Integration
268- ------------------------
269-
270- Besides providing a form type, the bundle also provides a Sonata Admin
271- Extension. This extension adds a field for the ``SeoMetadata `` when an admin
272- edits an object that implements the ``SeoAwareInterface `` in the Sonata Admin
273- panel.
274-
275- .. caution ::
267+ .. tip ::
276268
277- The Sonata Admin uses the Form Type provided by the CmfSeoBundle, make
278- sure you have the `BurgovKeyValueFormBundle `_ installed .
269+ The :doc: ` SonataPhpcrAdminIntegrationBundle < ../sonata_phpcr_admin_integration/seo >`
270+ provides an admin extension for the `` SeoAwareInterface `` .
279271
280272.. _`BurgovKeyValueFormBundle` : https://github.com/Burgov/KeyValueFormBundle
0 commit comments