Page History

Versions Compared

Key

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

...

Code Block
languagejs
linenumberstrue
<html>
<head>

<!-- Including the gigya.js script: -->
<script type="text/javascript" src="https://cdns.gigya.com/JSjs/gigya.js?apikey=INSERT-YOUR-APIKEY-HERE" ></script>
<script type="text/javascript">

// Changing the default look and behavior of the add-on using the 'params' object:
var params =
{
    showTermsLink:false, // 'terms' link is hidden
    headerText:"Please Login using one of the following providers:", // adding header text
    height:145, // changing default add-on size
    width:700,  // changing default add-on size
    cid:'',      
    containerID:"loginDiv", // The add-on will embed itself inside the "loginDiv" DIV (will not be a popup) 

    // Changes to the default design of the add-on's design

    //     Background color is changed to purple, text color to gray and button size is set to 40 pixels:    
    UIConfig:'<config><body><texts color="#DFDFDF"></texts><controls><snbuttons buttonsize="40"></snbuttons></controls><background background-color="#51286D"></background></body></config>',

    // Change the buttons design style to the 'fullLogo' style:
    buttonsStyle:'fullLogo',

    // After successful login - the user will be redirected to "https://www.MySite.com/welcome.html" :   
    redirectURL: "https://www.MySite.com/welcome.html"
}
</script>
</head>
<body>
<div id="loginDiv"></div>
<script type="text/javascript">
    gigya.socialize.showLoginUI(params);
</script>
</body>
</html>

...

Code Block
languagexml
linenumberstrue
<html>
<head>

<!-- including the gigya.js script -->
<style>
    body {font-family:arial;font-size:11px}
</style>
<SCRIPT type="text/javascript" lang="javascript"
    src="https://cdns.gigya.com/JSjs/gigya.js?apikey=2_Y82PzwJ_chSFImHXaIDJClnLyJzmk-VFOavSsaNTzl6m901s_NNxRAS0xJ3bd3_N">
    {
       enabledProviders: 'facebook,twitter,googleplus,linkedin,yahoo,messenger,aol,foursquare,vkontakte,renren,QQ,Sina'
    }
</SCRIPT>
<script type="text/javascript">

// Adding Flickr as a custom OpenID provider using the 'params' object:
customButtons= [
    {   // Flickr Button
        "type": "openID",
        "providerName":"Flickr",
        "iconURL": "https://s3.amazonaws.com/wikifiles.gigya.com/images/flickr.png",
        "logoURL": "https://s3.amazonaws.com/wikifiles.gigya.com/images/flickr_large.png",
        "lastLoginIconURL":"https://s3.amazonaws.com/wikifiles.gigya.com/images/flickr.png",
        "position":"4",
        "openIDURL": "https://me.yahoo.com/$USERNAME$"
    }
];	
var params =
{
    customButtons,
    "showTermsLink":false, // 'terms' link is hidden
    "containerID":"loginDiv" // The component will embed itself inside the "loginDiv" DIV (will not be a popup)
}
</script>
</head>
<body>
<div id="loginDiv"></div>
<script type="text/javascript">
    gigya.socialize.showLoginUI(params);
</script>
</body>
</html>

...

Code Block
languagexml
linenumberstrue
<html>
<head>

<!-- including the gigya.social.js script -->
<style>
    body {font-family:arial;font-size:11px}
</style>
<SCRIPT type="text/javascript" lang="javascript"
    src="https://cdns.gigya.com/JSjs/gigya.js?apikey=2_Y82PzwJ_chSFImHXaIDJClnLyJzmk-VFOavSsaNTzl6m901s_NNxRAS0xJ3bd3_N">
        {
            enabledProviders: 'facebook,twitter,googleplus,linkedin,saml,yahoo,messenger,aol,foursquare,vkontakte,renren,QQ,Sina'
        }
</SCRIPT>
<script type="text/javascript">

// Adding Media ID as a SAML login provider using the 'params' object:
customButtons= [
    { 
	    "type": "saml",
    	"providerName":"Media-ID",
        "idpName":"media-id",
        "iconURL": "//developers.gigya.com/download/attachments/8563756/loginButton.png",
        "logoURL": "//developers.gigya.com/download/attachments/8563756/loginButton.png",
        "lastLoginIconURL":"//developers.gigya.com/download/attachments/8563756/loginButton.png",
        "position":"4"
    }
];
var params =
{
    customButtons, // Includes the customButtons array
    "showTermsLink":false, // 'terms' link is hidden
    "containerID":"loginDiv", // The component will embed itself inside the "loginDiv" DIV (will not be a popup),
    width:200
}
</script>
</head>
<body>
<div id="loginDiv"></div>
<script type="text/javascript">
    gigya.socialize.showLoginUI(params);
</script>
</body>
</html>

...