This feature is not more available in Phoca Gallery.

 

In Phoca Gallery you can display images from your Facebook albums. What are the requirements to display the albums:

 

  • Facebook account
  • PHP function json_decode and cUrl enabled on your server 
  • If your server meets the requirements, go to Components - Phoca Gallery - Control Panel, click on Options and set Enable Facebook Image Loading parameter to Yes (it is enabled es default).

 

If you want to display Facebook albums (images from your Facebook albums) on your site, you need to create a Facebook Application in your Facebook account. This application is needed to communicate between your Joomla! site and your Facebook account. It will be your application so you will know, such application is secure and don't download your Facebook data into another page.

 

Facebook Settings
  • Login to Facebook
  • Go to "Create an Application" site - https://developers.facebook.com/setup/
    • Add site name
    • Add an URL of your site
    • Select language which your site is using
  • Create an application - App Name, App URL, App ID and App Secret values will be created.
  • Copy App ID and App Secret value.

 

Example: Phoca Gallery 4.2.2, creating Facebook application, API version 2.5

Phoca Gallery - Facebook Application creation

 

 

Phoca Gallery Settings
  • Be sure, Enable Facebook Image Loading parameter in options is set to Yes.
  • Go to Components - Phoca Gallery - Facebook, click on New. Add App ID and App Secret. Click on Save button (Facebook User Settings will be displayed after you will click on Save button - so first you need to fill in App ID and App Secret, then you need to save it and then additional settings will be displayed).

Phoca Gallery - Facebook Settings

Phoca Gallery - Facebook Settings

  • Connect with Facebook, login to your Facebook account. After successful login you will need to allow that your application can access your data. Then the page will be redirected back to the site where the parameters are listed. New button Paste Loaded Data will appear.

Phoca Gallery - Facebook - Paste Loaded Data

  • Click on Paste Loaded Data button. Now parameters will be filled. Click on Save & Close.
  • Go to Components - Phoca Gallery - Categories. Click on New. Navigate to bottom of the site and select Facebook User and Facebook Album.

Phoca Gallery - Select Facebook Album 

  • Click on Facebook Import button to import all images from the Facebook Album.

 

Phoca Gallery - Facebook Import

 

Phoca Gallery - Facebook Album Import

 

  •  Now all the images should be imported to Phoca Gallery.

 

Phoca Gallery - Imported Images From Facebook

Phoca Gallery - Imported Images From Facebook Phoca Gallery - Imported Images From Facebook

 

Phoca Gallery and Facebook Fan Page

Images can be imported/exported from/to Facebook fan pages too. If you want import/export images from/to facebook fan page, just follow guide above, but:

  • create two different accounts
    • First - standard Facebook user account (see above -  Components - Phoca Gallery - Facebook, click on New)
    • Second - Facebook user account with added fan page information (the same like standard user account plus fan page ID). Just paste loaded data with clicking on button and change Name parameter and add Fan Page ID parameter (this ID you can find e.g. while editing your fan page on Facebook site - in URL bar of your browser), see image:

 

Phoca Gallery Import/Export images from Facebook Fan Page - Settings

 

Now, you have two Facebook accounts in Phoca Gallery:

Two Facebook User Accounts in Phoca Gallery

First is your standard user account, second is your fan page account - both can be used while importing or exporting images from/to Facebook (from/to user albums or fan page albums). Just switch Facebook User parameter in editing of Phoca Gallery category.

 

 Facebook uses specific sizes for displaying images and thumbnails, for example:

 

  • Small thumbnail: 75x x 50px
  • Medium thumbnail: 130px x 87px
  • Large thumbnail: 720px x 482px

 

If the size of thumbnail or image is different from Phoca Gallery settings, then Phoca Gallery will try to correct the size. If you will use Phoca Gallery for displaying Facebook images, it is recommended to use the same size of thumbnails for Phoca Gallery which is used in Facebook. You can set the background images to fit Facebook size. See Styling Background Images article.

Phoca Gallery - Facebook Changing Background Image

Phoca Gallery - Facebook Changing Background Image 

 If you get following error: Session has expired then it means, stored session on your server expired. You need to go to: Joomla! administration - Components - Phoca Gallery - Facebook and click on edit current account. Login again to Facebook and paste loaded data - to refresh stored session.
Importing large albums from Facebook can be time and memory consuming. If you will get problems while importing, try to enable PHP error reporting on your server to get information about possible problems.