Skip to main content

Questions tagged [open-graph]

The Open Graph Protocol, invented by Facebook, provides a fixed vocabulary to embed meta data in a document head.

Filter by
Sorted by
Tagged with
0 votes
1 answer
95 views

how to test if an open graph image has been set

Our content mostly has Open Graph information set. I think this is done by Yoast SEO. Do you think this is correct? There are quite a few (~1200) URLs that have no Open Graph image set. I am thinking ...
Steve's user avatar
  • 1,747
0 votes
0 answers
746 views

Wrong Open Graph image is shown (og:image) using yoast

I am using Yoast plugin and have set the Open graph metadata, but the thumbnail image is wrong. I have set the same image in these places: Page editor > Social > Facebook image SEO > Search ...
Davood Dorostkar's user avatar
1 vote
2 answers
589 views

Target WooCommerce Product Gallery Image (rather than Featured Image) for og:image

I'm using the following code to set my Open Graph meta data in functions.php It works great for selecting the featured image, however I would like to set it to use the product gallery image instead (...
Daniel's user avatar
  • 21
1 vote
1 answer
57 views

what function can I use to automatically output og tags per page/post?

The issue: I had problem with my links social preview on WhatsApp and Telegram. The social preview appears on desktop and other platforms, also the Facebook debugging tool shows complete information, ...
joseph's user avatar
  • 13
1 vote
1 answer
137 views

Where does the Yoast SEO plugin set the Open Graph metadata?

The Yoast SEO plugin add this line to the head section of the page: <meta property="og:image" content="https://link.to.image.jpg" /> But according to FB OpenGraph og:image not pulling images (...
Ooker's user avatar
  • 332
0 votes
0 answers
96 views

Why does echo on functions.php not yield result in source code?

I follow the tutorial in How to Add Facebook Open Graph Meta Data in WordPress Themes and add some echo code in functions.php both in the main theme and child theme. However, when I check the source ...
Ooker's user avatar
  • 332
1 vote
0 answers
431 views

How can I add a second Open Graph image to a site using Yoast? [closed]

Through the Yoast SEO plugin, I've added a 1200 by 630 image for use by sites like Facebook and LinkedIn (and the image shows up with a complete set of og meta tags). I want to add a second open ...
Rich DeBourke's user avatar
0 votes
0 answers
58 views

Adding Facebook Open Graph Code does not work for Media Library Attachment Pages

I have code in my page header which properly creates the Open Graph tags for pages, posts, etc. However, when I attempt to Share an attachment post from the Media Library (not the actual attachment ...
jchwebdev's user avatar
  • 775
1 vote
0 answers
680 views

How do I change the permalink of a scheduled post so that it can be linked to?

When you create a post of any type (either post or page or custom taxonomy) it gets a permalink that visitors can click on and visit. http://example.com/my_first_blog_post_permalink/ However, if ...
jchwebdev's user avatar
  • 775
0 votes
2 answers
712 views

Yoast SEO plugin open graph add meta tag to fetch Avatar from Author Page

I'm trying to create a new og:image for author avatar when the users sharing their author profile page to Facebook. I'm a newbie with WordPress, After searching for more than 6 months but i'm always ...
Adham Mohamed's user avatar
1 vote
0 answers
500 views

How can I attach Facebook Open Graph data to an Attachment Page?

I have code in my page header which properly creates the Open Graph tags for pages, posts, etc. However, when I attempt to Share an attachment post from the Media Library (not the actual attachment ...
jchwebdev's user avatar
  • 775
0 votes
1 answer
405 views

rendering open graph meta tags in wordpress

I am trying to find some information about how to render/display Open Graph Meta Tags on my Wordpress page. What i found there is a lot of data how to set up this for social media, ADD Open graph ...
Greg Skala's user avatar
1 vote
2 answers
2k views

Sharing post in Facebook shows UTF8 invalid character �

I try to share posts from my website. The thing is the famous question mark diamond shows up on some of the posts description. All the OG Meta looks good (using Yoast SEO), it's 'just' the text on the ...
SagiLow's user avatar
  • 61
1 vote
1 answer
1k views

Using GraphQL Plugin with Pods Framework

So, I started to experiment with a GraphQL plugin for WP, and was wondering how it'd work with Pods. I came across a question on that plugin's GitHub that's pretty much the same thought I had. The ...
Robert Dundon's user avatar
0 votes
1 answer
379 views

how to edit open graph meta description programmatically and in which file

there is this site that I'm editing, I wanna know what file to look for while editing og meta desc. Excerpt seems to be empty on the page I want og desc for, still i'm seeing the desc on pasting the ...
popeye's user avatar
  • 191
0 votes
2 answers
413 views

Wordpress Facebook Open Graph plugin not working for 1 specific image [closed]

I have a really weird issue. I use the Facebook Open Graph, Google+ and Twitter Card Tags plugin to create open graph tags for my wordpress pages. Normally this works smoothly. It takes the first ...
beta's user avatar
  • 203
1 vote
3 answers
2k views

How to get full absolute url for post attachment?

I'm trying to manually fill the Open Graph tags and I'm having some troubles in setting the content for the og:image tag. In a single post page, I set it this way: <?php $thumbnailSrc = ...
Carlo's user avatar
  • 169
0 votes
1 answer
35 views

Facebook sharing content problem

I have problem when sharing posts (only posts) on Facebook, which is that there is no image or title or any thing but the blog link, while at the same time, I can share pages without any problem. I ...
Mohamed Omar's user avatar
1 vote
1 answer
2k views

How to Add custom subtitle as og:title to Facebook Open Graph Meta Data in WordPress Themes?

I am using wp subtitle plugin for headings in my Local language, and default wordpress title as English headings. I need the plugin generated subtitle as title of shared article on facebook. ...
kabeer shefy's user avatar
0 votes
2 answers
715 views

Open graph 'image' content appears empty on debugger and filled in web source

Defining Open Graph meta tags like this for images. global $post; $postImg = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), array( 1200, 9999 ), false ); <meta property="og:...
10Y01's user avatar
  • 59
0 votes
1 answer
2k views

Facebook Does Not Grab Correct og:Image

I have a small bit of code which creates the OpenGraph tags for each post. It seems to work OK, but the actual Featured image is not grabbed by Facebook when I copy the URL into a new FB post. Or ...
jchwebdev's user avatar
  • 775
-2 votes
1 answer
1k views

Force Jetpack to use og:url with http on an https website

I moved my site from http to https, but I wish to preserve my facebook likes. From what I read, I should use the og:url metatag so that facebook will know how to fix the likes on that page. I tried ...
Tal Galili's user avatar
  • 1,833
0 votes
1 answer
62 views

Plugin, add opengraph tags after form submit

Im developing plugin which calculates child date of birth and so on. So what I need is to add opengraph tags with appropriate data when someone wants to share the page on facebook. What i want is that ...
kroma's user avatar
  • 3
1 vote
0 answers
305 views

How can I echo og:video url, if the post has video content?

I would like to something simular solution like is_home() for videos. If the post has video content, the php script write out the og video url (start with https of course). In my example I imagine ...
InBug's user avatar
  • 31
2 votes
3 answers
3k views

Why I can't modified jetpack default blank.jpg on og:image?

I would like to change jetpack default blank.jpg atribute on og:image. I readed some artcile in this subject, but not realy helped me. Here some trys: /** * Override the default OpenGraph tags */ ...
InBug's user avatar
  • 31
1 vote
1 answer
65 views

How do I use this PHP library to access OpenGraph data in a child theme?

I'm fleshing out post formats in a child theme. For link-type posts, if a featured image hasn't been set, I'd like to fetch the OpenGraph image associated with the link and display it. I've found ...
SpencerDub's user avatar
1 vote
1 answer
585 views

Facebook preview Open Graph Object Debugger

if i try to publich my website on Facebook i have an error with the featured image. I try to use the facebook debug but i not have any interest information. I use this function but nothing resolve: ...
skifast's user avatar
  • 73
5 votes
1 answer
5k views

Is there a filter to define the OG image on a given post?

I am looking for a filter to define what image on a post sets the facebook OG image. In my case I have the image I want to use in a post meta field. I have looked around but am unsure of the best way ...
Shawn's user avatar
  • 432
0 votes
1 answer
6k views

Problems with Open Graph

I am ready to pull the remaining hair out of my darn head. Can't for the life of me figure out why Facebook will not pull the featured image, or even an image from inside the post, when I share via ...
Andy Graziano's user avatar
0 votes
0 answers
20 views

Checking if certain header meta data is set

I'm trying to see whether <meta property="og:title" content="..."> and other OG properties are included inside the <head> of a WordPress site. Does anyone have an idea on how to do that? ...
GauteR's user avatar
  • 131
0 votes
2 answers
540 views

How do I add Facebook OpenGraph meta tags for attachments in the header for a custom theme?

How do I add Facebook OpenGraph tags in the header when the header has already been called, and the values I need to add are obtained in the body? This is a highly customized theme (which I did not ...
Chloe's user avatar
  • 245
3 votes
2 answers
35k views

Set Custom Post feature image as og:image

I am trying to set the Featured image as the og:image I have tried various ways and plugins (Yoast) but finding it hard to get my head around this. The issue is that it isn't picking up the feature ...
Kenny Van Sittert's user avatar
1 vote
0 answers
413 views

Retrieve image from Open Graph of an external URL and set as featured image

I would want to retrieve an image of an external link in the content of a post, as to feature it as a thumbnail, sort of how a Facebook status or other similar things would look. I guess that an Open ...
peroyomas's user avatar
  • 339
0 votes
1 answer
58 views

How to find which plugin is outputting Open Graph tags to <head>

After getting an error the Facebook debugger about duplicate og:url tags, I'm trying to find which plugin is outputting the second set of Open Graph tags to my head section. I've tried deactivating ...
Joe Hallissey's user avatar
0 votes
2 answers
543 views

Website Preview Graphic for Wordpress Site

No idea how to ask this... so I'll give it my best. I have a Wordpress site, self hosted. When I post a link to a post on Facebook, Facebook tries to detect a preview graphic to show along with ...
Charlie74's user avatar
  • 105
0 votes
2 answers
3k views

Conditionally write open graph meta property in header

Have a function I use to print Open Graph tags in the header of each page I also have a plugin I use to post to Facebook which also puts in it's own set of basic OG Tags. Facebook doesn't like if a ...
Doug B.'s user avatar
0 votes
1 answer
31 views

Is it possible to add post specific info in head of worpress post for OG use

Im trying to implement this OG features on my site. http://www.jwplayer.com/blog/publish-your-videos-to-facebook-with-a-jw-player/ Is it possible to get post title, thumbnail url, and place it in the ...
Charles Wayne's user avatar
0 votes
0 answers
296 views

Facebook meta tags not working properly on WordPress Site

I want tow things in my site. First when any user click on facebook button to share any post it shwo image and content, title only and the 2nd one is when any one copy the link of my site and directly ...
Adi's user avatar
  • 340
0 votes
1 answer
6k views

OpenGraph descriptions not showing when using Wordpress SEO (Yoast)

I installed WordPress SEO a couple of days ago and have the Open Graph tags ticked, and they are all displaying fine apart from the page description. Should this be appearing, and am I correct in ...
pixelkicks's user avatar
1 vote
1 answer
144 views

Open Graph in posts loop page

I have a loop where all the posts have their own like button, when i click it the facebook window appears but it does not show the right post thumbnail. I think this is normal because in a posts loop ...
Nicola's user avatar
  • 127
0 votes
0 answers
1k views

FB - Comment Moderation Tool bug or error in the code?

I am an admin of this site. This blog uses the FB comments plugin since around 1 year. Since I enabled the July Breaking Changes, I: -am not receiving any more new comments notifications on FB; -New ...
utnalove's user avatar
2 votes
2 answers
5k views

Open graph metadata isn't pulled on Facebook until after I run that specific link through the debugger

I added open graph meta data to all the posts on a site, however, when I attempt to paste a post link on Facebook, the graph meta information isn't loaded. Then, when I insert the URL into the ...
Orun's user avatar
  • 390
0 votes
1 answer
858 views

OG:Audio facebook meta tags

Does anyone have any Idea how to populate the attached audio file URL into meta elements? Just as you would featured image or something Here's what I tried: <meta property="og:audio" content="<?...
shawn merrihew's user avatar
0 votes
2 answers
2k views

How to use author's avatar as Facebook post preview image when a single post is shared

I want to use the post author's avatar if available as the post preview image for Facebook shared posts. If that is not available next would be a featured image and then a default image as a fallback....
Drai's user avatar
  • 634
1 vote
1 answer
741 views

Facebook social publisher and custom post type fields [closed]

I have a problem with how Facebook plugin shows my WordPress-based posts on my timeline. What basically happens is that the post image isn't shown. Now, the post image I want to show is a custom ...
kappa's user avatar
  • 111
1 vote
1 answer
472 views

Generating the ogp tags in theme

I use to generate the ogp tags in themes I code but this commercial one is beyond my knowledge. The client want to share a page but any image option shows up. Instead of a taxonomy-name.php template ...
Diana's user avatar
  • 1,248
1 vote
1 answer
473 views

Conditionally add apt. Open Graph meta data to different pages on WordPress site

The official Facebook plugin does an excellent job of adding appropriate Open Graph meta tags to different pages (Home, Posts, Pages, Archives, etc.) of a WordPress site. The problem is it does many ...
its_me's user avatar
  • 4,512
1 vote
1 answer
901 views

Facebook "like" open graph meta in header.php

I would like to add open graph meta tags to my header.php, but can someone explain how this works if header.php comes before my loop with the relevant information?? <meta property="og:title" ...
redconservatory's user avatar
27 votes
3 answers
91k views

How to add code to Header.php in a child theme?

I'm creating a child theme for the first time and I had a few questions regarding code added to header. In a non child theme there is certain code I add to my header.php file such as google ...
Rick Smith's user avatar
1 vote
1 answer
5k views

Open graph problem: Showing wrong description of homepage while sharing on Facebook [closed]

Check out this URL: http://developers.facebook.com/tools/debug/og/object?q=www.linuxstall.com Everything is fine except the last line which is Note: "Reference in Perl" is the most recent post at my ...
Chankey Pathak's user avatar