Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with OpenID
Advertise on LowEndTalk.com

In this Discussion

PHP/Wordpress help needed with meta data in header.php

PHP/Wordpress help needed with meta data in header.php

GM2015GM2015 Member
edited September 2015 in Help

I'm having problems with php5.6 and wordpress 4.3. I want to have my facebook and twitter descriptions to be automated via php.

THe issue is twitter:image and facebook og:image is broken when php the post thumbnail is invoked. I manually choose a thumbnail that's most relevant to an article.

Here's the relevant header code: http://pastebin.com/CQv0rB0X

Relevant part's output code with my note there marked from firefox's source inspection: http://pastebin.com/adTjih9j

The thumbnail function is enabled in the wp theme function.php file and thumbnails work nicely on related posts and category and tag pages.

But I just can't get this working.

Twitter validator don't work so facebook scraper won't work either.

Thank you!

I should have added I used https://codex.wordpress.org/Function_Reference/the_post_thumbnail and neither of these worked.

Should op go sleeping instead?
  1. Go Home6 votes
    1. I'm tired too
      33.33%
    2. Lowendtalk.com is a place where serious businesses conduct deals and is not for asking questions.
      66.67%

Go give Vultr(referral) a try. | GNU/Linux http://debian.org

Comments

Sign In or Register to comment.