[Open Graph and Twitter Card Tags] Error handling [WordPress plugin]
This section explains how to deal with errors in WordPres plug-in “Open Graph and Twitter Card Tags“.
Contents
Error
Error: Facebook Open Graph Tags cache NOT updated/purged.
Facebook returned: (#100) Must have a valid access token or a valid url_hmac
…
Cause of the error
The cause of the error is not due to the plug-in update, but is due to a change in the specifications on Facebook.
Facebook stopped accepting non-authenticated calls to the clear cache URL.
How to deal
The developer explains how to deal with it in the support forum.
Create Facebook app ID
Create a Facebook App ID on the Facebook for Developer page below. If you have already created, the created app ID will be displayed on the following page.
https://developers.facebook.com/apps/
Copy app ID and app secret
Make a copy of “App ID” and “app secret”. Each item can be confirmed by “Dashboard”-> “Settings”-> “Basic”.
Edit functions.php
Add the code to “functions.php” in the theme file.
“functions.php”
//Open Graph and Twitter Card Tags add_filter( 'fb_og_update_cache_url', 'my_fb_og_update_cache_url' ); function my_fb_og_update_cache_url( $url ) { $url .= '&access_token=[app ID]|[app secret]'; return $url; }
Reference site
- Open Graph and Twitter Card Tags » Hi i got this trouble when updating to 2.1.4
- Facebook Open Graph, Google+ and Twitter Card Tags with Access Token · GitHub
記事がお役に立ちましたらシェアお願いします!