Was this article helpful?

Gigya Module for Drupal

Last modified 08:54, 26 Oct 2014

drupal

Overview

The Gigya Drupal module allows you to easily integrate Gigya's Consumer Identity Management platform throughout your Drupal site. Achieve a single customer view by collecting and consolidating profile and activity data, and tap into first-party data to reach customers with more personalized marketing messaging.​
The Gigya module enables Customer Identity Management and a wide range of social Plugins and Gamification, all fully configurable and can be controlled from your Drupal site administration.

Please refer to module page on Drupal.org - http://drupal.org/project/gigya 
 

Versions

Recommended Version

The recommended version for production use is 7.x-4.6.

View update details on the latest and earlier versions in our change log

Legacy - Drupal 6

If your site uses Drupal 6, please use this link http://drupal.org/node/1515084 to download our latest version for Drupal 6.

Please refer to the Gigya for Drupal 6 documentation.

 

Main Features

  1. Customer Identity Management - Gigya’s Customer Identity Management is a complete solution for managing a new generation of user data that encompasses social identity data, social graph connections, behavior data, and traditional profile data. Gigya module for Drupal provides two main packages:

    • Social Login - The Gigya module can be used as an external authentication system, allowing users to sign up to your site using an increasing number of platforms, such as Facebook, Twitter, Google, LinkedIn, Yahoo, and more. As with standard registration, new Drupal user accounts will be created in the process. See our documentation for additional information and advanced implementation options: Social Login.

    • Registration-as-a-Service(RaaS) - An end-to-end user management system package. The platform offers a comprehensive cloud-based user registration system that supports Social Login, allowing sites to maintain a unified user database for both social and traditional site authentication. Learn how to implement RaaS within Drupal. For additional information and advanced implementation options: Registration-as-a-Service.
  2. Share - The module includes different tools to enable your users to share content and site activities to social networks. The Share Bar plugin displays a bar of buttons, next to whatever content you wish, for sharing this content to social networks and bookmark destinations. Sharing an action lets the site owner configure rules to automatically prompt the user with a share dialog, once he performs a certain share-worthy activity on your site, encouraging the user to post his action to social networks. The activity can be for example, posting a story, or submitting a comment, etc. See our documentation for additional information and advanced implementation options: Sharing Content.

  3. Comments - Gigya's Comments plugin enables site users to post comments and have discussions about published content on your site. These comments can be easily shared with social networks. By default, enabling Gigya comments will replace Drupal’s comments with Gigya’s. Gigya’s comments are configured to also be saved as Drupal comments, so the plugin can be easily be switched-off - while still retaining the comments. Please notice that Comments settings must be configured on Gigya’s site, before they can be used in your Drupal site. Login to www.gigya.com to configure these settings. 

  4. Ratings & Reviews - The Rating & Reviews plugins give your customers an easy way to provide feedback on product and content across your site, and then share that feedback with friends in their social networks. With Ratings & Reviews users can post reviews on any type of content displayed in your website, as well as rate the content on a 5 star scale.

  1. Reactions - The Reactions plugin allows users to react to content in your site and share their reaction to social networks. The Reactions plugin is built out of one or more buttons, arranged in a bar. Each button represents a "reaction" to the content, such as 'LOL', 'Amazing', etc. Once a user clicks on a reaction button, a share dialog will pop up to suggest to him to share his reaction to social networks. 

  2. Gamification (GM) - Gigya's Gamification is a social loyalty and rewards platform that can be easily embedded in your website, increasing site engagement and making your users' experience more enjoyable. 

  3. Activity Feed - The Activity Feed plugin allows users to see the latest actions on a site, according to who performed the actions. 

  4. Follow Bar - The Follow bar plugin is a bar of social providers that allows users to follow your business on social networks with only one click.

Adding Gigya's Drupal Module to Your Site

Adding Gigya's Drupal module to your site is easy and requires no programming skills.
Just complete the following simple steps, each step is explained further below.

  1. Install the modules required for Gigya's module to work.
  2. Download and install the latest Gigya module.
  3. Enable the Gigya module on your Drupal site.
  4. Enter your site's API key and Secret received from the Gigya Console.

Your API keys will be quickly validated and your site will be ready to add Gigya's social features.

 
Note: The Gigya module uses the user's email as a main identifier. Make sure to have permission to retrieve user emails as described here.
 

Installing the Required Modules

Gigya requires the following modules be installed on your site in order to be enabled.

If you do not have them installed on your site, go to each of the links above and install them.
Installation is quite similar to the installation of Gigya's module. You can follow the same steps or use Drupal's module installation guide.

 

Downloading and Installing Gigya's Drupal Module

There are basically three ways to install the Gigya module on your Drupal site. 

  • By feeding Drupal's module installer a URL to the latest compressed module file.
  • By downloading the file and uploading it to the module installer.
  • By directly uploading the module to your site.

While the module installer is much more user friendly, it will not work on all servers. Uploading it directly to your site requires direct access to the files on your host.
Regardless of the installation method that you select, It is recommended to download the 
latest release.

The Gigya social infrastructure module can be found in the downloads section of this page.

For more instructions on adding external modules to Drupal visit this page.

Enabling the Gigya module

Enabling a module is done by checking the checkbox on the right of the module and clicking the 'Save configuration' button.
Note that Gigya's module requires a few other modules to be enabled before you can activate it. Every module lists the modules that it depends at the bottom of the cell, and their status to assist you in activating it.

requiredModules.jpg

Entering Your Site's API Keys

The last step of setting up Gigya's module for Drupal is to fill-in your site's Gigya API key and Secret key.

To obtain the key, log in to the Gigya console and navigate to the home screen. Your site's API key will appear in the 'API key' column next to your site's domain.
To obtain your secret key, select your site domain from the drop-down menu titled 'Select your site:' at the top of the window. Next click on 'show secret key.
showSecretKey.jpg

Now that you have your site's keys, navigate to Configuration >> web services >> Gigya settings. De-collapse the 'Gigya socialize keys' menu, and enter your API key and secret key in the appropriate fields.

socializeKeys.jpg

That's it. Your site is now installed with the Gigya module and ready to use.

 
Note: The Gigya module uses the user's email as a main identifier. Make sure to have permission to retrieve user emails as described here.
 

Gigya Module Configuration & Customization

Admin Configuration

After the Gigya module has been installed, it can be configured through the Admin Configuration Panel under the Gigya entry (Configuration>>Web services>>Gigya settings).
Under 'Gigya', you'll find the following tabs which correspond with the features available with the Gigya module:

  1. Global Settings - Global Settings are general settings affecting all the Gigya features.
  2. User Management Settings​ - Enable and configure the Registration-as-a-Service (RaaS) or Social Login.
  3. Share Settings​ - Enable and configure the Gigya Share plugin.
  4. Comments Settings (or Rating & Reviews) - Enable and configure the Comments plugin or the Rating & Reviews plugin. 
  5. Reactions Settings - Enable and configure the Reactions plugin.
  6. Gamification Settings​ - Enable and configure the Gamification plugin.
  7. Activity Feed Settings - Enable and configure the Activity Feed plugin.
  8. Follow BarEnable and configure the Activity Feed plugin.

 

Further customization is possible through the use of Hooks and Tokens. Read more on the advances customization page.

Global Settings

The settings in this section define basic configurations of the Gigya integration on your Drupal site.
 

Field Default  Description
Gigya API key (no default) Paste the API key for your site domain that was generated for you at the Gigya site (please refer to the installation guide).
Gigya Secret key (no default) Paste the Gigya Secret key for your site domain that was generated for you at the Gigya site (please refer to the installation guide).
List of Providers * The default * setting specifies all available networks. Otherwise type a comma-separated list of networks that you want to include. For the full list of available providers, refer to the global configuration object page. 
Language English
The module supports localization. In the list, select a supported language for display on your website.
NOTE: If your desired language is not in the list, please refer to the language support section. You then add the relevant string to the Additional Parameters below.
Enable Google Social Analytics No Select Yes to enable the Google Social Analytics plugin.
For details, please refer to the 3rd-party Analytics Integration page.
Data Center US Data Center

The location of the data center associated with your Gigya account. Default is 'US', however if you are using a different one (e.g Europe) please change it here.

Options are:

  • 'US' (United states) - default option
  • 'EU' (Europe)
  • 'AU' (Australia)
  • Other

When selecting the 'other' option, you will be prompted to enter the name of your data center. This option is meant to support data centers that are added between versions, adding the path to them explicitly ( e.g. the URL for the European data center is eu1.gigya.com, therefore the prefix for it will be 'eu1').
The name is an acronym that represents the data center you will be using. If you are not sure, contact your implementation manager to receive the name of your data center.

Login Behavior Login existing user
For users not logged into the site, this field determines login requirements for performing a Gigya social action (for example, sharing, reacting, or commenting).
  • Always login – before proceeding with the Gigya social action, users are first directed to site login.
  • Login existing user (Default) – social actions are allowed with no requirement to log into the site. Behind the scenes, the following happens when such users successfully access one or more social networks:
    • Registered site users are automatically logged into the site.
    • Other users are logged into the site as temporary users.
Gigya advanced settings (no default)
This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section below.
For the list of available configuration options, please refer to the Global Conf page.
Technical note: the Global Configuration automatically fulfills the Gigya requirement to insert a Global Conf block of code in the header section of any page of your website that has a Gigya block in the page body (the block calls the main Gigya JavaScript library and initializes the Gigya API. The configuration is passed as an object to the script call).
     
Gigya Debugging No Check this to enable the Drupal Watchdog. When checked, the module logs all of Gigya's requests and responses into Drupal's Watchdog logging system. Learn more about Drupal Watchdog.

Remember to click the "Save Changes" button before continuing.

 

Advanced Settings
Most of the Gigya settings tabs include an "Advanced Settings" box. This box enables you to specify configuration options beyond those available in the other fields for that tab.
Additional parameters must be entered in "JavaScript Object Notation" (JSON) format. The required format is {"key1": "value1", "key2": "value2", "key3": "value3", "key4": "value4"}​ where "key" represents the name of the API method parameter and "value" is the value you are passing to it. For example, the following use of JSON sets values for the Global Conf object's enabledProviders and ShortURLs fields: {"enabledProviders":"facebook, twitter", "shortURLs":"whenRequired" }

 Additional Parameters

Note: The Additional Parameters in all sections override existing configurations, and must be used carefully.

 

User Management Settings

The settings in this section configure the part of the module that relates to user registration and management (RaaS and Social Login).
There are four basic options, and the settings displayed vary depending on the option you select:
  • Drupal only - This (default) option disables Gigya's login and Gigya's user management and uses Drupal's native login.
  • Drupal + Social Login - This option enables Gigya's social login, allowing users to login to your site using their social networks. User management is handled by Drupal.
  • Social Login only - This option enables Gigya's social login and disables Drupal's native login, allowing users to register and login using only their social identities.
  • Registration-as-a-Service - This option enables both Gigya's social login and Gigya's user management, giving you extended data and control over your site users and enabling the RaaS feature. 

user-management-settings.jpg

 
Drupal + Social Login (or Social Login only)

If you choose to enable Gigya's social login without Gigya's registration-as-a-service, then the following User Management Settings are displayed:

 
Field Default  Description
Button style Standard This parameter enables selecting one of the pre-defined design styles for the network buttons on the Login UI. 
Currently Gigya offers the following design styles: 

'standard' (default) 
showLogin-standard.jpg
'fullLogo'  
 showLogin-fullLogo.jpg
'fullLogoColored'
showLogin-fullLogoColored.jpg
'signInWith'
showLogin-signinWith.jpg
Post Login Redirect (no default) This parameter defines where the users will be redirected to once they have successfully logged in to the site.
You can enter any URL, or leave the field empty. If the field is left empty, the page will reload after the user logs in.
Hide title no Hide login block title.
Show terms link No Select Yes to display a link to the Gigya terms of use agreement.
Width 210 Specify the display width of the login plugin in pixels. Available after checking the 'set custom size for plugin' button.
Height 110 Specify the display height of the login plugin in pixels. Available after checking the 'set custom size for plugin' button.
Advanced ShowLoginUI Settings (no default)
This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
For the list of available configuration options, please refer to parameters table in the socialize.showLoginUI API page.
Advanced ShowAddConnectionsUI 
Settings
(no default) This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section. For the list of available configuration options, please refer to parameters table in the showAddConnectionsUI API page.
 
 
 
Enabling Social Login activates the Login plugin. The Login plugin appears on the Drupal 'User Login' block, alongside the standard Drupal login form, as seen in the screenshot on the right.
The login plugin will also appear in the Drupal login and registration page when navigating to {your site domain}/user - e.g www.mydrupalsite.com/user.
You can use the Login plugin to customize the sign-in options within your site, as explained in the table above.
For more information on the Login plugin, you can refer to the Login plugin page and to the socialize.showLoginUI API method.
wordpress-socialogin-page.jpg
 
Registration-as-a-Service

As a first step please follow the instructions specified in the Using RaaS with Drupal page.
The predefined default screen-set IDs in the following section were changed for sites defined in the Gigya Console after September 2014. 
The following table relates to the new screen-sets definition. If you are having problems viewing screen sets, you could be running an old version of the Gigya module, that configures  
earlier screen-set versions that came with RaaS Out-Of-The-Box configuration before October 2014
Please consult the screen-set update guide for more information.

Field Default  Description
Login/Registration Screen Sets     The screens used for new user registration and existing user login. For more information, see the Screen-sets tool and the Default Screen Sets. Changes to these settings require prior definition of screen-sets.
Web Screen Set ID Default-RegistrationLogin Name of a web screen-set containing the screens used in managing user login. Sites added to the Gigya Console before September 2014 should set this parameter to "Login-web​".
Mobile Screen Set ID DefaultMobile-RegistrationLogin Name of a mobile screen-set containing the screens used in managing user login. Sites added to the Gigya Console before September 2014 should set this parameter to "Mobile-login​".
Login Screen ID gigya-login-screen Name of the initial user login screen. This is a screen defined in the web and mobile screen-sets (with the same name in both). The default screen set uses the same screens with different CSS.
Register Screen ID gigya-register-screen Name of the new user registration screen. This is a screen defined in the web and mobile screen-sets (with the same name in both). The default screen set uses the same screens with different CSS.
Profile Screen Sets    The screens used for entering and updating user profile information.
Web Screen Set ID Default-ProfileUpdate Name of a web screen-set containing the screens used in entering user profile details. Sites added to the Gigya Console before September 2014 should set this parameter to "Profile-web​".
Mobile Screen Set ID DefaultMobile-ProfileUpdate Name of a mobile screen-set containing the screens used in entering user profile details. Sites added to the Gigya Console before September 2014 should set this parameter to "Profile-mobile​".
Link's Labels    The labels of the links that will invoke the screen-sets.
Login login Within Drupal's login page.
Register register Within Drupal's Registration page.
Profile profile Within Drupal's Profile page.
     
Post Login Redirect (no default) This parameter defines where the users will be redirected to once they have successfully logged in to the site.
You can enter any URL, or leave the field empty. If the field is left empty, the page will reload after the user logs in.
Map Drupal username field RaaS email address Options are "RaaS email address" and "RaaS username field".
Drupal requires a unique username field. By default the module sets the field with the user's email. If you select  "RaaS username field", the Drupal username field will be set with the user's RaaS username. When selecting this option please make sure to define the username field in RaaS to be required and unique. Learn more in Adding a Unique Required Username Field.
Mapping RaaS Fields to Drupal Fields   Gigya provides the ability to integrate user data fields from RaaS to Drupal, by mapping corresponding fields in the from Gigya (source) to Drupal (target). Read more in Updating Profile Data from Gigya to Drupal.
 

Enabling Registration-as-a-Service enables Gigya's complete user management feature. After completing configuration of RaaS as explained in the Gigya configuration section, the standard Drupal login-link will no longer appear. Instead, the RaaS login | register links will appear (assuming you have enabled the "Gigya RaaS links" block). Clicking them will open the RaaS login / register pop-up screen (example on the right) to allow users to login/register using RaaS.

Note: To access the Drupal dashboard after activating Gigya's RaaS enter /user after your site's URL, as in http://<www.your-Drupal-site.com>/user

 

raas-login.jpg
 

Share Settings

The Gigya Share Bar plugin allows users to share stories to social networks. 
share-widget.jpg
You can easily integrate the Gigya Share Bar in your Drupal site by defining a container for it in the Gigya>>Share settings page. Read more on the 'Adding Gigya plugins' section.
You can select the share providers you would like to have by writing them in the 'Share Providers' field, separated by a comma. 

 

Field Default  Description
Container ID gigya-share the ID of the HTML DOM element that will contain the share bar.
Share Buttons  share,facebook-like,google-plusone,twitter,email Type a comma-separated list of share buttons to display. For the full list of available providers, refer to the socialize.showShareBarUI API page.
Share Bar Layout Horizontal Horizontal or Vertical. 
Show counts Right Specify if and where (right or top) to display the number of times a share button was clicked for this product.
Scope for publishing
to activity feed
Both

Options are: 'External', or 'Both'

When publishing feed items, by default the feed items are published to social networks only and will not appear on the site's Activity Feed plugin. To change this behavior, you must change the publish scope to "Both".

Default share title [node:title] Default title to display for the share item post. 
Default share description [node:summary] Default description for the share item post.
Default linkback URL [node:url:absolute] Default linkback to which the users will be directed when clicking on the share post.
Image use image tag if exists Instructions on where to retrieve the image for the post item.
Options are:
  • First image on the post.
  • Specify an image URL.
  • Use image tag if exists, first image on post otherwise - If an image URL was specified, use it. Otherwise, use the first image that appears in the post.
Share using short URLs no Check this box in order to user short URL.
Token List   Quickly insert tokens into one of the settings fields by clicking a field followed by clicking the desired token.
Advanced settings (no default)
This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
For the list of available configuration options, please refer to parameters table in the socialize.showShareBarUI API page.

 

Comments Settings (or Rating & Reviews)

The Gigya Comments enables site users to post comments and have discussions about published content on the site.
The Gigya Rating & Reviews give your customers an easy way to provide feedback on product and content across your site.

The Ratings & Reviews plugin is an extension of the comments plugin, and can be set in the Gigya admin console when creating a new comments category.

The Comments & Reviews plugin also requires setting up in the Gigya admin console by following the steps described in the Comments plugin page.
Note: Gamification is a premium package that requires separate activation. If it is not part of your site package please contact your Gigya account manager or contact us by filling in a support form on our site. You can also access the support page by clicking "Support" on the upper menu of Gigya's site.

Both the Gigya Comments and Rating & Reviews plugins supports SEO, meaning the comments/reviews content is searchable by the main search engines.

 

Comments  OR  Rating & Reviews
comments-widget.jpg  

RatingUI.gifRating&Reviews.jpg

 

To use this plugin, define a Category ID in Gigya's Admin Console and enter it below, then set "Enable Gigya Comments" to Yes. The rest of the settings are optional.

Field Default  Description
Enable Gigya Comments No Select Yes to enable the Comments plugin or No to disable it.
Gigya comments Category ID   Enter the name of a comment category that you have set up in the Gigya console. To define a comment category go to the Gigya Management Console, Settings>>Comments>>Comments Setup. To learn more please refer to the Setup a New Comment Category on Gigya's website.
Container ID comments The container ID that the comments will be displayed in. 
Scope for publishing
to activity feed
Both

Options are: 'External', or 'Both'

When publishing feed items, by default the feed items are published to social networks only and will not appear on the site's Activity Feed plugin. To change this behavior, you must change the publish scope to "Both".

Do not load Drupal comments yes If checked Drupal comments will not load, only Gigya comments will be loaded. Note: this may harm the site's SEO as comments will not be indexed by search engines
Advanced settings (no default)
This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
For the list of available configuration options, please refer to parameters table in the comments.showCommentsUI  API page.

 

Note: the Drupal module implementation internally sets the "streamID" parameter with the node ID value. That way each comments instance has its own unique steamID value - the ID of the post that the comments are about. 
         This can be overridden using the advanced settings or using hooks.

 

Reactions Settings​

The Gigya Reactions plugin enables users to share defined reactions to site products on user social networks.

This plugin displays a set of buttons like the following in a webpage:
Reactions counters

Reaction buttons are defined by a comma separated list of JSON objects. Each object defines a single Reaction button to be displayed in the reactions bar. Please refer to the Reaction object for the specification of the object structure.

You may also use Gigya's Reactions wizard. Make sure you are logged-in to Gigya's website, you may access the wizard by clicking the "Plugins" tab, and then the "Reactions" on the side bar.

Note: To define the reactions buttons, or to paste the buttons code produced using the Reactions wizard, follow the instructions under the 'Placing a Plugin Content Field' section in the 'Adding Gigya plugins' section.
If you copy Reactions from the Reactions wizard, please make sure that you paste only the Reactions buttons' objects and not the entire code.

 
Field Default Description
Container ID gigya-reactions The container ID that the comments will be displayed in. 
Bar ID reactions-bar ID of the reaction bar.
Reaction title [node:title] Default title to display for the share item post. 
Default linkback URL [node:title] Default linkback to which the users will be directed when clicking on the share post.
Layout Horizontal Horizontal or Vertical.  The direction in which the buttons are arranged.
Use multiple reactions Yes Select Yes to allow a single user to activate multiple reactions, when set to No only one reaction bar is allowed per user.
Count type Number Number or Percentage. The reaction button count is shows as a literal number or as a percentage of the total buttons pressed.
Scope for publishing
to activity feed
Both

Options are: 'External', or 'Both'

When publishing feed items, by default the feed items are published to social networks only and will not appear on the site's Activity Feed plugin. To change this behavior, you must change the publish scope to "Both".

Image use image tag if exists Instructions on where to retrieve the image for the post item.
Options are:
  • First image on the post.
  • Specify an image URL.
  • Use image tag if exists, first image on post otherwise - If an image URL was specified, use it. Otherwise, use the first image that appears in the post.
Advanced settings (no default)
This box enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
For the list of available configuration options, please refer to parameters table in the socialize.showReactionsBarUI API page.
Token List   Quickly insert tokens into one of the settings fields by clicking a field followed by clicking the desired token.

 

Reactions Code Sample:
The following sample code displays these Reaction buttons Reactions widget
{
    text: 'Amazing',
    ID: 'amazing',
    iconImgUp:'http://cdn.gigya.com/gs/i/reactions/icons/Amazing_Icon_Up.png',
    iconImgOver:'http://cdn.gigya.com/gs/i/reactions/icons/Amazing_Icon_Down.png',
    tooltip:'This item is amazing',
    feedMessage: 'This is amazing!',
    headerText:'Your reaction to this post is \'Amazing\''
}
,{
    text: 'Geeky',
    ID: 'geeky',
    iconImgUp:'http://cdn.gigya.com/gs/i/reactions/icons/Geeky_Icon_Up.png',
    iconImgOver:'http://cdn.gigya.com/gs/i/reactions/icons/Geeky_Icon_Down.png',
    tooltip:'This item is geeky',
    feedMessage: 'This is geeky!',
    headerText:'Your reaction to this post is \'Geeky\''
}

 

Gamification Settings

Gigya Gamification is a social loyalty and rewards platform that you can embed in your website, increasing site engagement and making your users' experience more enjoyable.  To use this plugin check the "Enable Gigya Gamification" checkbox.
he rest of the Gamification settings are optional.

The Gamification plugin also requires setting up in the Gigya admin console by following the steps described in the Gamification plugin page.
Note: Gamification is a premium package that requires separate activation. If it is not part of your site package please contact your Gigya account manager or contact us by filling in a support form on our site. You can also access the support page by clicking "Support" on the upper menu of Gigya's site.
 

 

 gm.gif

 

Field Default  Description
Enable Gigya Gamification Yes Check this box to enable the Gamification plugin or No to disable it.
Enable Gamification Notifications Yes Check this box to enable popups notifying the user of Gamification achievements: See Notifications for more details.
Leaderboard time period All Displays for the top users for the challenge within the set period: See Leaderboard for more details.
Leaderboard user count 12 Select a number between 1 - 23 to set the number of users displayed in the leaderboard.
Advanced Settings (no default)
This section enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
Each box sets the advanced settings for the corresponding plugin.
For the list of available configuration options, please refer to parameters table in the appropriate method's API page:

 

Gigya Gamification Blocks

The Gamification blocks section in the Gamification settings tab is a quick way to configure and deploy some of Gigya's game mechanics plugins, such as User Status and Leaderboard.
These plugins display GM stasts and update live as the user performs actions that affect the state of the plugin. To learn more go to the Game Mechanics plugins section.

When adding multiple instances of a plugin, you will need to define a block to contain each instance of the plugin and will be placed in your web page.
For example, you might want to place one "User Status" plugin in your website's header, and one in the footer. To achieve this you will need to create two blocks, each containing an instance of the "User Status" plugin, and place one in the header and one in the footer. 
In order to create a block, follow the following steps:

  • Under the 'Gamification' tab, go to the 'Create a new block' box
  • Enter a name for your new box. It is recommended to use a name relevant to the purpose of the box, so for the first box of two that will contain a 'User Status' plugin, a name like
    'User_Status_1' will be appropriate. 
  • Check the box next to the plugin you wish to create (in our example:  'User Status').
  • Click 'Create a block' .
  • Click 'Save configuration' to save the changes you made (at the bottom of the page).

 newBlock.jpg

In order to place the plugin on your site, go to configuration >> Structure >> Blocks. Find the Newly created block, and in the 'Region' column select the section of the site where you want to place the plugin.

To remove a block simply check the box next to it in the 'Delete blocks' section and click on 'Delete'.

deleteBlock.jpg

 

Defining Actions

Gamification challenges are propelled by actions. Using GM to define challenges, users can then perform actions to earn points for their engagement. 
The Gigya module allows you to synchronize activities on your Drupal site with predefined actions, defined in the challenges section of the console.

To integrate actions into your site, you will need to download, install and enable the rules module.

Once you have the rules module set up, go to Configuration >> Workflow >> Rules.
You will see the following screen:

Rules.jpg

Now name your action by filling out the required 'Name' text box, and select an event to react on from the 'React on event' drop-down list.

If you wish to limit the action to specific pages, select a page type from the 'Restrict by type' drop-down. Else, the action will be called every time the reaction event occurs. 
For instance, if I select the 'Content is viewed' event, and not restrict by type, the event will trigger every time a page is loaded. However, if I select to restrict by type to pages of type 'Article' alone, the event is triggered only in case an article page is loaded. 
Click 'Save' to continue to the following screen:

AddActionScreen.png

Under the 'Actions' section, click on addAction.png.

From the 'Select action to add' drop-down, select 'Gigya game mechanics action'.

GMActions.png

The following drop-down will contain the actions defined in the Gigya console. 
Select the action you want to associate to the event you have created.

selectAction.png

Click 'Save' to complete the process, and repeat until all the actions you wish to trigger on your site are associated with a rule in Drupal.

Activity Feed Settings

The Gigya Activity Feed plugin enables users to see the latest actions on a site, according to who performed the actions. The Activity Feed plugin can display elements like the following in a webpage:

 File:015_Partners/030_CMS_and_Ecommerce_Platforms/050_Magento/clipboard_1370273404186.png

The following plugins are supported by Activity Feed:

  • Gigya Share
  • Gigya Reactions
  • Comments Settings (or Rating & Reviews)

This means that actions that are performed on the above plugins (e.g. user shared a product) are reflected in the Activity Feed.


 

Field Default  Description
Enable Gigya Activity Feed No Check to enable the Activity Feed plugin or uncheck to disable it.
Activity feed container ID ActivityFeedDiv The ID of the container that will hold the activity feed.
Tabs and order (none) Possible tabs are Everyone, Friends and Me. For an example, see the basic running example.
Set custom size for plugin No Check to set the Width and Height of the plugin.
Custom Width (none) plugin width. Available in 'Set custom size for plugin' is checked.
Custom Height (none) plugin height. Available in 'Set custom size for plugin' is checked.
Activity Feed privacy level Private Private, Public and Friends. See Privacy Levels.

 

Follow Bar​ Settings

The Follow Bar widget allows you to easily place a bar with different buttons for following news and keeping updated through different communications channels, such as a Facebook page, a Twitter account, a newsletter, a blog, etc. The Follow Bar widget is built out of one or more buttons, arranged horizontally or vertically in a bar. Each button represents one of the supported providers:

FollowBar.png

Once a user clicks one of the buttons, a "follow" action takes place; taking the user to a new window, or redirecting the user, or opening a provider-specific dialog.  

 

Field Default  Description
Container ID gigya-follow-bar ID of an element on the page in which you want to display the Follow Bar. 
Orientation  Horizontal

The orientation of the Follow Bar.
Options are:

  • 'Horizontal' (default)
  • 'Vertical'
Icon Size 52 The size of each icon displayed in the Follow Bar (in pixels).
Follow Bar Buttons   An array of FollowButton objects.
Advanced Settings (no default)
This section enables you to specify configuration options beyond those available in the fields above. For details, please refer to the Advanced Settings section.
Each box sets the advanced settings for the corresponding plugin.
For the list of available configuration options, please refer to parameters table in the socialize.showFollowBarUI page:

 

Adding Gigya Plugins to Your Page (Blocks & Fields)

Overview

This section explains how to add Gigya's social plugins to your website.
Some plugins require some configuration before they can be added to your site. 
Note that some of the plugins require setting up on the Gigya admin console. See the relevant plugin settings section for details.

After configuring the plugin, you can add it to a specific page, or to all pages by placing it in a specific area on your website. 

A Gigya plugin can be defined as a field inside a 'content type' or in a 'Block'. Look for the annotation at the top of the plugin configuration page to find exactly which method is used for placing the plugin inside a page.

placeNewBlock.jpg

 

Enabling the plugin

First, some plugins require activation. Look for the 'Enable' checkbox at the top of the settings tab of the plugin you wish to add, and make sure it is enabled.

enablePlug.jpg
 

Placing a Plugin Block On the Page

In order to add a Gigya plugin as a block to your website:

  • Go to Structure >> Blocks
  • Find the block you wish to add in the list. If the plugin hasn't been added to the site yet, it will probably be under the 'Disabled' section.
  • Open the drop down menu and select the area in which you wish to position the plugin
  • Click 'Save blocks' at the bottom of the page

blockPosition.jpg

 

Placing a Plugin Content Field On the Page

In order to add a Gigya plugin as a field in your content type:

  • Go to Structure >> Content Types
  • Find the content type you wish to add the plugin to and click 'Manage Fields'
    For example: the following screenshots shows a website with two content types - Article and Basic page.

selectContentType.jpg

  • From the 'Add new field' row, enter a name for the plugin instance you wish to add
  • Choose the plugin type from the drop-down menu under 'Field type' 
    For example: in the following screenshot shows how to select the Ratings & Reviews plugin to add to the selected content type.
    addField.jpg


Next, you will need to fine tune the plugin to match display settings of the plugin in the admin console

  • Click the 'Manage Display' tab on the top right of the page. 
  • On the row of your newly added plugin, click the configuration button on the right. 
    config.jpg
  • The row will de-collapse, presenting configuration fields for that specific plugin. 
    For example, for a 'Ratings & Reviews' plugin, you will need to specify the 'Category ID' as defined in the Gigya admin console, and the 'Comments container ID' as defined in the 'Comments & Reviews' tab in the Drupal configuration section.

    pluginSettings.jpg
     
  • This is also the place where you should define the content of the plugin when necessary. i.e - defining reaction buttons, or sharing providers for the 'Share bar' plugin.

    recationButtons.png
     
  • When checking the 'Override default settings' checkbox (see above image), the settings defined in the configuration menu will override the corresponding settings defined in the Gigya module Admin Configuration and will only effect the instance of the plugin that you are creating.
    This is useful when trying to create a unique instance of a plugin that serves a different functionality. 
  • Click 'Update' to submit the changes to the plugin.
  • Click 'save' to update the page with your changes.

That's it. A new Gigya social plugin will appear on your site in the position you defined.

Working With Panels

Gigya's plugins can also be added to panels, if you have the panels module installed and enabled.
The Gigya module also has a 'Panels integration' that you should also enable from the 'Gigya' section of the 'Modules' page.

gigyaPanels.png

When adding a new panel, make sure to add context to the panel, as some of Gigya's plugins require context and will not be available for embedding on the panel otherwise.
Add context by checking the 'Contexts' checkbox under the 'Optional features' section in the first page of the 'Add panel' flow.

Context.png

Next you will be prompted to select the context for your panel from the available contexts drop down menu.

selectContext.png

Select the context you would like and click on 'Add context'. Based on the context you selected, you will be required to enter an identifier to an instance of that context.
For example, if you selected the 'node' context, you will need to enter an ID on an existing node entity on your site.

contextID.png

That's it as far as Gigya requirements. When finished with the panel creation flow and you want to add a Gigya plugin to your panel, simply click on 'Add content' from the settings menu

addContent.png

On the pop-up window, select Gigya from the left hand side menu

leftMenu.png

Select the plugin you wish to add from the list of plugins available (if you are missing some plugins, make sure that you have defined context to your panel) and click 'Finish'.

gigyaPlugins.png

Adding Multiple Plugins To a Panel

When adding more than one plugin of the same type to panel (i.e two follow bars), you need to define different ID's for the plugin containers, as the default ID cannot be assigned to more than one container.
This is done by checking the 'Override default settings' checkbox on the widow that follows selecting the plugin.

overrideSettings.png

Once you check the box, further configuration options will be available to you.
Change the name of the container ID (e.g gigya-follow-bar2) to enable two instances of the plugin to appear on the page.

 

Consumer Insights Notifications

Consumer insights (CI) is where you as a site owner can analyze information regarding your users' engagement and activity. 
View the CI reports in the consumer insights page of your Gigya admin console.

CI works by binding signals to counters. The signal triggers the increment of the counter, which is then represented in the corresponding CI report. 
There are a few default counters that need no prior configuration to collect data. You can also define custom counters to track specific signals that are not counted by default.
 

Adding Custom CI Notifications

Custom CI counters use the rules module installed. If you haven't yet -download, install and enable the module.

Once you have the module set up, go to Configuration >> Workflow >> Rules. 
On the rules page, click on addNewRule.png from the to left side of the page. 
Next you will arrive at the new rule page where you will have to select a name and an event to trigger your event:

newRule.png

You can name your rule freely, however note that the event you select will be responsible for triggering a signal that will increment the counter that you will bind to in the next step.
Make sure to choose an event that represents the counter you wish to increment through it.
After selecting an event you will get a drop-down menu that enables you to limit the event signals to specific pages.

 restrict.png.

This can help you fine tune the signals that trigger your counter, although it is not required.
 

Available counters that are not incremented automatically are:

  • Ad click
  • Purchase

You can also create custom counters via an API call to accounts.registerCounters.

Next step is to define the action to be performed as the signal triggers.
On the next page click on addAction.png  from the 'Actions' section at the bottom of the page. 
You will be redirected to the 'Add new action' section where you will need to select an action from the drop-down menu.
From the drop-down, select 'Notify Gigya signal' from the Gigya section.

GigyaSignal.png

The Last step is to configure the counter for the signal you have created.
The next page enables you to define the counter parameters:

  • Class
  • Path
  • Value
  • Count (Signal count)

When finished, click 'Save' to complete the process and start tracking user actions on your site. Go to the consumer insights section in your console to query the data.

 

Note: Newly added Classes and Paths will appear only after the cache is cleared.

 

Debugging

To view runtime information, enter "Drupal.settings.Gigya" in the site console.

In addition you may use Gigya's various Debugging Tools.

 

 

Was this article helpful?
Pages that link here
Page statistics
1242 view(s) and 8 edit(s)
Social share
Share this page?

Tags

This page has no custom tags.
This page has no classifications.

Comments

You must to post a comment.

Attachments