[Support request] Where to place structured data markup in generate press?

Home Forums Support [Support request] Where to place structured data markup in generate press?

Home Forums Support Where to place structured data markup in generate press?

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #620837
    Derek

    Hi,

    I’m using Google’s tool, and the instructions say:

    “Select JSON-LD from the dropdown menu. Copy the code and paste it into the <head> or <body> tags in the HTML code of the respective page on your website.”

    Do I use the GP Hooks? I’m assuming no because that’s global right? Is there a way to do this in GP or do I need a plugin to insert code like this into individual pages?

    I ready somewhere that GP was schema ready so IDK what that means, but I certainly didn’t want to break anything!

    Thank you!

    #620988
    David
    Staff
    Customer Support

    Hi there,

    you can use GP Hooks, and wrap the code within an a Conditional tags like so:

    https://docs.generatepress.com/article/using-hooks-conditional-tags/

    Or wait a little while for GPP 1.7 which will make this super easy.

    #621689
    Derek

    Thanks, it will be a while before I get to implementing this anyway. Any idea when 1.7 will be out?

    #621694
    Leo
    Staff
    Customer Support

    The first beta has been out for awhile and a second beta is about to out as well.

    You can test it out:
    https://docs.generatepress.com/article/beta-testing/

    More info:
    https://generatepress.com/gp-premium-1-7/

    #825417
    Michael

    Hi
    I am wanting to add my structured data but can’t find any documentation on how to do it or what this thread was alluding to about it being super easy….can you guide me?
    Thanks

    #825496
    David
    Staff
    Customer Support

    Hi there,

    the plan to integrate JSON-LD into the theme was put on hold, its planned for a later update but is a significant change so needs to be done right.

    You can use GP Hooks to include your Structured Data:

    https://docs.generatepress.com/article/hooks-element-overview/

    Or you can use a dedicated JSON-LD Structured Data plugin.

    #825711
    Ender
    #825713
    Michael

    Thanks I did it using a hook and it was 5mins to set up and has passed googles mark up testing tool so I am all good thanks.

    #825839
    David
    Staff
    Customer Support

    Glad to hear that 🙂

Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.