Archive for Tag ‘Plugin‘

Introducing WPGPlus: Posting from WordPress to Google+

Inspired by seeing comments in Google+ about the need for a WordPress cross-post, I whipped up a quick WordPress plugin: WPGPLus.

For now, since the Google+ API is read-only, I’m borrowing inspiration from Luka Puši?’s GPlus Bot and Dmitry Sandalov’s Twitter 2 Google Plus script.

This means emulating the Google+ mobile web experience using Curl.

WPGPlus adds a box to the post edit screen where you can choose yes/no for publishing to Google+, as well as a place for a message to be used in the body.

(If you provide a Google+ message it is used; if you provide a post excerpt it is used; otherwise post content is used).

Anyway, check it out and let me know what you think!

WPBook and WPBook Lite: More Options, More Flexibility

A few months ago I discussed the Future of WPBook in this space, specifically what to do about Facebook’s new requirement that all applications providing canvas pages or page tabs had to be accessible via SSL. As I outlined it then, I saw the options as:

  1. Eliminate the canvas page and tab altogether – make WPBook just focus on cross-posting and comment import, thus potentially eliminating the SSL requirement?
  2. Make it optional – keep the canvas page and tab, but make them optional – only for users who want them and have the necessary SSL certificate
  3. Fork the plugin – make a version of the plugin which works like the current model, but also a second (WPBook Lite?) that only does cross posting and comment import? That way we could have separate directions for each to simplify setup confusion
  4. Stop developing WPBook – There are a number of other plugins which do Facebook posting, and at least one which does Facebook comment importing (probably more). Is it worth continuing to develop WPBook if better alternatives exist?

Ultimately, I settled on Option 3: Fork the plugin, and create a lighter-weight version which did not include the canvas page or tab. The result is WPBook Lite, available now in the WordPress Plugin Repository.

Should I use WPBook, or WPBook Lite?

I suspect this will be the main question folks will face, so here’s a quick comparison table:

Feature WPBook WPBook Lite
Cross Post WordPress Blog Posts to Facebook X X
Post WordPress Blog Posts to Facebook Profiles (Walls), Pages, and Groups X X
Import comments made against Facebook Excerpt Posts to WordPress as native comments X X
View WordPress Blog inside Facebook as Canvas Page Application X
Add WordPress blog as a tab to a Facebook Page X
Requires WordPress blog be accessible via SSL (HTTPS) X

Basically, if you are able to access your blog via HTTPS, and you WANT the view of the blog inside Facebook as a canvas application, or you want the page tab feature, you should use WPBook.

If your blog is not accessible via HTTPS, or you don’t want the view of the blog inside Facebook / page tab, then you should be happier with WPBook lite.

I’ll be updating the instructions over at WPBook.net shortly to reflect Facebook’s new look for developer settings shortly, and will also differentiate between WPBook and WPBook Lite. In theory, configuring WPBook Lite should be significantly simpler for most users.

If you’re already using WPBook and shift to WPBook Lite, you will need to regrant permissions.

Migrating from WPBook to WPBook Lite:

  1. View your WPBook settings page, and write down your profile ID as well as the IDs of any pages/groups to which you want to cross publish.
  2. Deactivate WPBook (but don’t delete it yet)
  3. Install and Activate WPBook Lite
  4. Set up a new Application for WPBook Lite – this time you should only need the “Website” settings under Integration, not any of the “App on Facebook” section settings
  5. Visit the WPBook Lite settings page in WordPress, fill out the required fields (APP ID, Secret, your profile ID), and save the form
  6. Re-visit the WPBook Lite settings page, where you should now see an opportunity to grant appropriate permissions

If done correctly, WPBook Lite should pick up right where WPBook left off.

If you run into problems, please comment in the appropriate WordPress Support Forums: WPBook or WPBook Lite.

The Future of WPBook

I’ve been doing a lot of thinking about the future of WPBook, and wanted to give a quick update. There are two key factors making me rethink the whole approach.

Pittsfield in the Near Future (from Cameo Wood on flickr, cc-by-nc license)

The first is a change Facebook has made, requiring SSL certificates for “all Canvas and Page tab applications.” (They announced this change earlier this summer, as part of the bizarrely Orwellian “Operation Developer Love” but it went into effect as of October 1st).

This is a problem because many WPBook users’ blogs are not available via https connections (including my own), and with this new Facebook change their WPBook implementation will fail, though how exactly that will be manifest isn’t clear to me yet (see below). Getting an SSL certificate for your blog isn’t an insurmountable task, but if you run your blog on cheap shared hosting, the costs of an SSL certificate (and the dedicated IP it requires) can be nearly as much as you’re paying for hosting! It’s also a task that the non-technical user will find horribly confusing.

The second is a recent report showing that:

Using a 3rd party API to update your Facebook Page decreases your likelihood of engagement per fan (on average) by about 80%


Read more…

WPBook 2.2.1

Try Again (Photo by Samantha Marx, cc-by license, http://www.flickr.com/photos/spam/3355834452/)

Spent some quality time this weekend with WPBook. As a result, I just released version 2.2.1. (There was briefly a 2.2 release, but something was corrupted in that version of the SVN repo, so use 2.2.1 instead).

Included in 2.2.1:

  • Read More is back. Re-enabled the “Read More” action link. Unfortunately, because of a Facebook API bug wpbook can’t add more than one action link to a post, so no “share” button on wall posts until that is fixed. (Facebook doesn’t add the Share link automatically to posts from the Graph API and there’s currently no way to make that happen other than manually adding it as a link, but I think the “Read More” link is more important.)
  • Post to Group Walls. Added posting options for Group walls, and comment import form Group walls. Because of the way the Facebook API has changed, posting to a Group feed is distinct from posting to a Page’s feed, and requires different syntax.
  • Controlled debugging. Limit the size of debug files created to 500k, so that users who enable debugging and then forget won’t have an unlimited file growing every hour. Also made the debug constant more specific to WPBook so as not to interfere with other plugins potentially using DEBUG as a constant
  • Fopen errors. Clean up DEBUG for cases where permissions fail or file is not writeable
  • Facebook::$CURL_OPTS . Made “disable ssl verification” an option so that only users who need it will have it and others won’t get conflict
  • Required fields are required. Cleanup to the admin screens in general, more clarity around what is required and better language on the admin screens about what is being checked. (Thanks BandonRandon for patches)
  • Better check permissions. Improved “Check permissions” page, to show what options mean and enable links to view profiles, pages, links to validate IDs are correct.
  • Added wpbook logo which had been missing
  • Fix for get_themes() issues with WordPress 3.0.1 through 3.0.5

I realize from the activity in the forums that many users are having trouble with the 2.1 and later WPBook – but I believe all the known errors have been fixed, and most are due to misconfiguration.

A few configuration notes that might help:

  1. Your application ID, secret, canvas URL, and Profile ID must be correct or nothing else is going to work. If you load your application canvas page and you don’t see the WPBook theme, but see just your blog in an iframe (unchanged), then something is wrong in your Facebook Application setup, your WPBook setup, or in a plugin conflict.
  2. Your personal FB profile is absolutely required, even if you don’t plan to publish to your profile’s wall. It is through the FB profile that the access_token for publishing to pages is retrieved. If your FB profile ID is wrong, nothing else is going to work.
  3. Any time you change the Profile ID, the Page ID, or the Group ID to which you are trying to publish, you must visit the Check Permissions page and will most likely need to regrant permissions. Again, if permissions aren’t working, nothing else is going to work.

If you’re stuck, please open a new thread in the wordpress forums and provide the following debugging info:

  • The URLs of your Facebook Application and your blog outside FB
  • The contents of your check permissions page – verbatim
  • What you are trying to publish to – profile, page, group – by ID and by URL
  • What error messages you are seeing, in the WordPress interface and/or in the PHP error log

With the right information, we will be able to get it working.

Thanks

WPBook 2.1.4 Released

Code Bug (Photo by Guilherme Tavares, cc-by license, http://www.flickr.com/photos/guitavares/1703252007/)

Just released WPBook 2.1.4.

Two key bugfixes in this release:

  1. Comment Imports. In changing to the Graph API I needed to add an access_token to the FQL calls I’m using to retrieve comments from non-public streams.
  2. Facebook Avatars for Pages. Given that you can now comment on wall posts as a page (by using the “use Facebook as page” option if you are the admin of a page) some of your comment authors in FB might be pages themselves. This fix will get the right FB avatar for them, eliminating what was otherwise a broken link image.

There should not be any need to regrant permissions or change any Facebook settings in this release.

Thanks to all the users who’ve provided feedback (and debug files!) in the forums.