Site logo

Archived topic

Open Graph and Schema.org formats for marking up your pages

3 replies · Started by Terrell Jerry on September 14, 2021

Viewing posts 1–4 of 4

Hello, does generate press support Open Graph and Schema.org. I'm applying for rich pins.

You can copy and paste this example text into your page's head tag. Just change the content to match your page.
<head>
<meta property="og:type" content="article" />
<meta property="og:title" content="Exploring Kyoto's Sagano Bamboo Forest - CNN.com" />
<meta property="og:description" content="A constant inclusion on lists of "forests to see before
you die," here's how to see the real thing." />
<meta property="og:url" content="http://www.cnn.com/2014/08/11/travel/sagano-bamboo-forest/" />
<meta property="og:site_name" content="CNN.com" />
<meta property="article:published_time" content="2014-08-12T00:01:56+00:00" />
<meta property="article:author" content="CNN Karla Cripps" />
</head>

How do put this into my website?

I look forward to your response.

thanks,

JERRY

Hi Jerry,

You can use a Hook Element to add that to your site's wp_head.

See more about Hook element here -
https://docs.generatepress.com/article/hooks-element-overview/

What you basically do is paste that code on the Hook Element's code area.

You then set the "Hook" option to "wp_head" and then go to "Display Rule" tab and set the "Location" to the page you're supposed to add that on. :D

Does that go code go onto one of my articles for article rich pins to work?

I'm not sure what the context of your code is and it sounds like it's supposed to be dynamic.

If that's actually the case, I think you may be better off using a plugin to set it up for you.

Like this one.
https://rankmath.com/kb/rich-snippets/

This archived topic is closed to new replies.