Page History

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


Quick Start Implementation

Include Page
Template_gigya setup sn app
Template_gigya setup sn app

Include Page
Enable Retrieving User Contacts Notice Template For Share
Enable Retrieving User Contacts Notice Template For Share

Implementation Overview

If you already have included Gigya social login in your site, adding Share should be simple, and involves only adding a few lines of code:

  • Construct a UserAction object, which represents an action taken by a user on your site. The basic elements you need to include in the object are:
    • Title - The title of the posted content.
    • Link Back - A link that typically points to the content source.
      Include Page
      Share URL Restrictions Template
      Share URL Restrictions Template
    • Description (optional) - A description of the story or item.
    • Media Item/s (optional) - This can be image/s, a Flash file (inc. video players), or an Mp3 file.
Note: It is highly recommended to implement Open Graph Tags directly on your HTML, for better structured news feed post on Facebook ('like'), Twitter and Google (+1).
This way native sharing when copy-pasting your site URL will structure the share post as defined.



  • Call the showShareUI API to activate the Share add-on and enable the user to share his action.

Code Example

Add the following code snip to activate the Share add-on that is presented in the screenshot above:

Code Block
// Constructing a UserAction Object
var act = new gigya.socialize.UserAction();

// Setting the Title
act.setTitle("This is my title");

// Adding a Link Back

// Setting the Description
act.setDescription("This is my Description");

// Adding a Media (image)
act.addMediaItem( { 
    type: 'image',      // Type of the media (image/flash/mp3)
    src: '',   // URL to the image source
    href: ''    // URL to redirect the user when he clicks the image

// Activate the Share add-on
gigya.socialize.showShareUI({  userAction:act });