[Plugin: WPBook] "Post for iFrames Canvas urls"
-
This setting does appear on my facebook application settings. How can I enable it?
-
I followed all instructions for version 2.1 upgrade (except Post for IFrames Canvas URLs because it is not there), and my posts are not appearing on facebook. The permissions look correct:
This user_id has granted these permissions:
offline_access – yes
read_stream – yes
publish_stream – yes
This user has set an access_token for the application to use.
…
You’ve indicated you wish to publish to this page: 113115355391983This page has granted stream.publish permissions to this app.
I don’t see any errors in wpbook_debug.txt, and I don’t get any errors when I post. How can I track down the issue?
I should add that this was working fine before the upgrade.
What exact error are you getting? Also, maybe “post for iframe canvas urls” is a bit deceiving you should have the “POST for Canvas” enabled. Your advanced settings should look like this
Hello,
I am not getting any error, but the posts are not going to my facebook wall, even though the permissions seem to be correct. My advanced settings page does NOT look like yours. See here.
I wonder why they are different?
The settings page is different based on when the app was created – this is the joy of Facebook’s evolving API and part of why troubleshooting is difficult. ??
What’s the URL of your Facebook App, and what’s the URL of your blog outside FB?
Do you have “show errors when publishing to Facebook stream” enabled in your WPBook settings?
Are you trying to publish to your individual profile page wall, or a fan page wall, or an application page wall, or a group page wall?
I’m trying to publish to a fan page: https://www.facebook.com/pages/Knife-Depot/113115355391983
facebook app is https://apps.facebook.com/knife-depot-blog/
blog is https://www.knife-depot.com/blog/
I do have “Show errors posting to Facebook Stream” checked, but I don’t see any errors when I create a new test post. Where would I see them? They aren’t appearing in the debug file either.
I noticed that a post we put up last night (the one about nuclear power plant) is appearing on our facebook app but not on the facebook fan page. My understanding is that the purpose of the facebook app is to post to the other facebook fan page.
Any ideas?
The app has multiple purposes – it is a view into your blog, where people can comment, AND it serves to manage permission to post to your page, AND it enables permission to read comments off your wall.
Have you tried, with yourself logged in, to shift a post from “published” to draft and then back to “published” again? (Basically republishing the post).
The permissions look correct – just wonder if the trigger mechanism is failing.
OK, here is the error I get now:
“Caught exception in publish to page (#200) This API call requires a valid app_id. Error code: 0”
What could be causing that?
I did verify that the facebook app DOES have all permissions to the facebook page it is trying to post to.
Another oddity – I don’t see this error when posting as an admin, but if I am posting as an editor, I DO see the error.
I dug into the code and printed out the facebook error object:
[result:protected] => Array
(
[error] => Array
(
[type] => OAuthException
[message] => (#200) This API call requires a valid app_id.
))
I can send more of it if you want me to. Email me at [email protected] and I’ll send it that way to avoid cluttering up this page.
more weirdness… I tried to just completely remove my app ID from WPBook, and it just stays there. Where is this stored? Maybe I can manually remove it.
I think I know what the problem is – I’m storing the access_token associated with a specific WordPress userid – but at the point you are posting that userid is not the current_user.
Need to store the access token as a global setting for WPBook since it is that access token that is used regardless of who is posting.
(The error message refers to app_id, but my guess is that what’s actually wrong is the access_token).
Quick patch: open wpbook/includes/publish_to_facebook.php, and find, around line 35:
if(version_compare($wp_version, '3.0', '<')) { $access_token = get_usermeta( $current_user->ID,'wpbook_access_token'); } else { $access_token = get_user_meta($current_user->ID,'wpbook_access_token',true); }
Replace $current_user->ID with the user id of your admin user (likely ‘1’)
I will roll this into a 2.1.2 – will basically need to retrieve that data from the user_meta table and move it into a wpbook setting somewhere.
OK, I changed those lines of code, but I am still seeing the same issue. The app ID won’t stay clear when I erase and it and click save. I don’t get any errors when publishing a post, but they don’t appear on the facebook page.
- The topic ‘[Plugin: WPBook] "Post for iFrames Canvas urls"’ is closed to new replies.