Friday, 18 November 2011 01:00

Joomla K2 AutoFBook Documentation

Written by 
Rate this item
(0 votes)

Joomla K2 AutoFBook is an advanced and easy to use Joomla plugin, that automatically publishes your K2 articles to Facebook. So your Facebook fans instantly sees when you have new content.

This documentation describes how to set this plugin up.

Installation

Install the plugin like any other extension. For details on how to install extensions, look at the installation guide at the Joomla community.

General Settings - Activating the plugin

The plugin is disabled by default after installation, so our first step is to activate and set up the plugin.
This is done in the plugin manager (Extensions -> Plug-in Manager).

Plugin Manager

You will be presented with a list of all the installed plugins. Look for the plugin name System - K2 AutoFBook Plugin, and click on the name to enter the settings.

In the plugin details, you'll find the setting for Enabled which you set to "enabled" to make the plugin active. The appearance of these settings are different between Joomla 1.5 (left picture) and Joomla 1.6 and higher (right picture) as seen bellow.

Joomla 1.5Joomla 1.7

 

Step 1 - Create a Facebook Application

The first step is to create an application at the Facebook Developer page. This is necessary since it's the only way for programs to communicate with Facebook. Enter the advanced parameter settings of AutoFBook Plugin, and click on "Create a Facebook App".

AutoFBook Create App

 

Choose an appropriate App Display Name, For example your site name  or site adress. Click on Continue to enter the next step in the app creation.

 

Under the section Basic info, enter your App Domain which usually will be your website adress without www, as seen in the screenshot below. Also enter your full website adress in the Site URL field, which you'll find if you click on website as seen below.

 

Save all your changes, and your're ready for the next step.

 

Step 2 - Get the App ID and App secret

At the top of you Facebook app page, you will find App ID and App Secret for your app.

Copy the App ID and App Secret from you Facebook application (on the Facebook developer site) and paste them in to the corresponding fields in your Joomla plugin parameter settings:

If you want to post to a Facebook page, you also need to enter a Page ID in the general Plugin Parameters.

 

You will find the Page ID in the url to your Facebook Page. The page id is the number you see as a part of the adress.

 

 

Save your changes, and you're ready to go.

 

Step 3 Authorize your website to Facebook

The next step is to give your website permission to use Facebook on your behalf. To initiate the authorization process, go to the K2 items Manager the Joomla backend, creat a new item and simply save it.

When you save your article you will redirected to the Facebook oAuth Dialog, and asked to authorize your website to use Facebook. Note that this will only be needed the first time you save an article after installing the plugin, or if you haven't been using the plugin for a while.

Click on Go To App, to continue to the next step.

The Dialogue will show all the pages that you have administrator rights to, and list all the permissions needed for the plugin to work. Allow all these permissions without any changes.

Facebook will redirect you back to your Joomla backend, and a message is displayed to show you that your app is now authorized. This step was necessary before posting to Facebook, and you will now have to re-visit the article you've just edited and simply save it again.

If all went well you will se the message below:

In some cases Facebook will fail to authorize the app the first time because of overloading. When this occurs you only need to try and save the article again.

 

Step 4 Enjoy your automatic marketing

 

All the posts sent to Facebook will be nicely presented on your Facebook Page.

Frequently asked questions

How do you find a Fan Page ID?

Take a look at the adress to your fanpage:

http://www.facebook.com/pages/Stilero-AB/223802977656746

The numerical ID at the end of the adress is the ID that you use in the Plugin settings

Optional - Set a date

You have the option to make the plugin only post articles newer than the date you set under "Post items newer than". This option should be useful when you don't want to post outdated news to your Facebook page.

General settings - Category ID

If you only want specific categories of articles (items) to be posted to Facebook, this is where you set it. Enter the numerical ID of the categories you wish to use separated by comma. All other categories will be skipped. If you leave this blank, all K2 categories will be sent to Facebook.

For example; lets say you only want to sent K2 articles (items) in the categories "Blog" (id 5), "Information" (id 12) and "News" (id 34). The setting in this field would be: 5,12,34

Don't put any spaces after the comma.

Where do I find a category ID?

Go to Categories and look in the rightmost column for ID. This i where you find the Category ID.

How does it work?

The updates are triggered in two ways:

  1. When an item i saved and published immediatelly.
  2. When a page with an scheduled item gets visited.

What happens under the hood is the following:

  1. When an article is saved the plugin makes some checks:
    • Is the item published?
    • Is the item for the public?
    • Is the item in a category that is set to be updated?
    • Is the item already sent to Facebook?
    • Is it to early to send an update according to the settings?
    • And some other checks...
  2. If no problems occur, the plugin initiates the Facebook communication
  3. If thearticle is set to be published in the future then the plugin waits until the publish date.

Troubleshooting

I don't see any posts on my Facebook Fan Page

Solution: Check that the "Post as admin" setting is turned on. Otherwise you will post to the page as a regular user. Posts from regular users are only shown if you switch section on the Facebook Fanpage wall, to the "Everyone (Most Recent)".

Joomla Facebook post as user

My posts to a Fanpage fails

Solution: Make sure that you are an admin of the page you are trying to post on. Otherwise it will not work as a regular user.

Read 975 times Last modified on Tuesday, 21 February 2012 12:38
Daniel Eliasson

A programmer and webdesigner with over 15 years of experience in different programming languages with a toolbox consisting of: Objective C, JAVA, C++, PHP and many more techniques.

Stilero på Twitter

I feel like I'm too obsessed with cleaning and refactoring code.But when I look at the code a couple of months later I know it was worth it.

by Daniel Eliasson

Follow Stilero Webdesign


Google+