Sign In

How to Implement – SLI.js

No registration is needed. All you have to do is include the javascript file and add at least 1 link with the proper class name:

        <script> var SSOobjParams = {} </script>
        <script src=""></script>
        <a href="#" class="ssosignin">Sign In</a>

Optionally, you can specify callbacks for errors or success:

        var SSOobjParams = {
                errorfunc: function(xhttpobj,errorstatus,errortext) {
                    alert('ERROR: '+errortext);
                successfunc: function (userdata,usercontacts) {
                    console.log(userdata); // hash of data about user
                    console.log(usercontacts); // array of contacts from the user
                    var str = 'Thanks for logging in';
                    if (userdata.displayname) str=str+', '+userdata.displayname;

Leave a Reply