Hello
I cannot get an image to work for my Twitter card. I am using a Youtube URL as the src, which is set via a WordPress custom field - this works fine for my Facebook meta property.
My code is:
<meta name="description" content="A few hot tracks every week selected by James Winfield.">
<meta property="og:title" content="House Minimal Techno Disco">
<meta property="og:image" content="http://www.houseminimaltechnodisco.com/wp-content/themes/hmtd/images/hmtdwide.JPG">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="House Minimal Techno Disc">
<meta name="twitter:image" content="http://www.houseminimaltechnodisco.com/wp-content/themes/hmtd/images/hmtdwide.JPG">
<meta name="twitter:description" content="A few hot tracks every week selected by James Winfield.">
<?php if ($youtube != '') {
echo '<meta property="og:url" content="' . $youtube . '?>" />';
echo '<meta property="twitter:image" content="' . $youtube . '?>" />';
echo '<meta property="twitter:image:src" content="' . $youtube . '?>" />';
}
?>
<meta property="og:description" content="A few hot tracks every week selected by James Winfield.">
An example URL where this should be showing is below:
Whenever I use the Card Validator, or tweet it, the standard no-image image shows.
This is also the case if I hard-code the image instead of using the PHP block.
Does anyone have any suggestions? I have checked through the list and spent a good couple of hours trying to find a solution but to no avail.
Kind regards
James