OroCommerce Forums

Covering OroCommerce topics, including community updates and company announcements.

Forums Forums OroCommerce How can I add SEO Keyworsd to Product programmatically?

This topic contains 3 replies, has 2 voices, and was last updated by  mlozynskyy 6 years, 9 months ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #31855

    mlozynskyy
    Participant

    How can I add SEO Keywords to Product programmatically?

    If I do in that way: I get an error “An exception has been thrown during the rendering of a template (“There must be only one default title”) in vendor/oro/commerce/src/Oro/Bundle/SEOBundle/Resources/views/SEO/keywords_view.html.twig at line 3.”

Viewing 3 replies - 1 through 3 (of 3 total)
  • Author
    Replies
  • #31856

    wgozdzicki
    Participant

    Hello,
    If you want to add keywords for the default localization you have to write something like this:

    You need loop only when you have more than one localization:

    #31857

    wgozdzicki
    Participant

    To be precise, when you have more then one localization still you have to add value for the default one with localization set to null.

    Best regards
    Wiktor

    #31858

    mlozynskyy
    Participant

    @wgozdzicki thank You

Viewing 3 replies - 1 through 3 (of 3 total)

The forum ‘OroCommerce’ is closed to new topics and replies.

Back to top