I have been on this for days now. Here’s my problem:
When I share the URL’s for my posts and some of my pages, it appends “Page Not Found” to the Title (og:title) and shows a random string for the Description (og:description). It works fine for most of my pages, but not for some and all of my posts.
Here is an example of a URL that is not working when shared on Facebook:
http://filminstitute.upd.edu.ph/event/saving-sally/?instance_id=207
Please take a look:
When posting the URL of a page that works, this is what it looks like and what is supposed to be happening:
When I run my URL’s in the Facebook Share Debugger, here is what I been getting:
I initially believed that the problem could be solved by adding the following meta tags to the header of the Website like this:
<meta property="og:url" content="<?php get_permalink() ?>" />
<meta property="og:title" content="<?php the_title(); ?>" />
<meta property="og:type" content="website" />
<meta property="og:image" content="<?php get_header_image(); ?>" />
<meta property="og:description" content="UP Film Institute" />
But as you can see in the images I provided, the title and description meta have not responded to the tags in the header.
Other things I have tried:
- Changing the OG meta from the functions.php – nothing changed
- Installing Yoast SEO – nothing changed
- Performed a command line search on all the plugin files for code snippets that manipulate og:description – 1 instance found, commented out, nothing changed
Can anyone point me in the right direction regarding what to do with this? I have been working on this problem for days now.
I would greatly appreciate any help I can get.
Thank you very much in advance.
3
Answers
You sample url shows
might be an issue with the printing the image url using your get_header_image function.
The issue is not Facebook at all. It’s DNS. When I was at home, I posted the following:
When I visited the website at work, the site looked COMPLETELY different and the links passed through fine. If the site DNS is breaking, then I’d bet on Facebook actually pulling the old one, and since those links may not have existed, that’s why you’re getting the 404 issues.
This is what I see at home:
Try changing the property in your header file from this:
To this: