-
Hi there,
We just recently noticed an issue regarding the meta tags for facebook and twitter. Specifically, we found that the opengraph and twitter image meta tags were completely missing from the head. Looking through the help/support forums, I found this article to troubleshoot the issue and narrowed things down to our custom template.
Investigating our template, I found that the issue seems to stem from a few lines of code that make use of the restrict_mimes_for_author() function.
add_filter('upload_mimes','restrict_mimes_for_author');
function restrict_mimes_for_author($mimes) {
if (!current_user_can('administrator') && !current_user_can('editor')) {
return;
}....Rest of code
}
When commenting out the entire function or simply the 3 lines of the if condition, the content appears in the header. If it’s exists, I can only see it in the HTML when viewing while logged into an admin or editor account.
Thanks!
The ticket ‘Social Images missing from’ is closed to new replies.