Created
August 16, 2012 13:17
-
-
Save renatosnrg/3370033 to your computer and use it in GitHub Desktop.
Social Login Widget
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
//<![CDATA[ | |
var e = document.createElement('script'); | |
e.type = 'text/javascript'; | |
e.id = 'socialid_login_script'; | |
if (document.location.protocol === 'https:') { | |
e.src = 'https://app.socialidnow.com/javascripts/marketing/login/widgets/login.js?1343653084'; | |
} else { | |
e.src = 'http://app.socialidnow.com/javascripts/marketing/login/widgets/login.js?1343653084'; | |
} | |
var s = document.getElementsByTagName('script')[0]; | |
s.parentNode.insertBefore(e, s); | |
function loadSocialIDLoginWidget() { | |
SocialID.SocialLogin.load('<social_login_id>', 'socialid_login_container'); | |
}; | |
if (window.addEventListener) { | |
window.addEventListener('load', loadSocialIDLoginWidget, false); | |
} else { | |
window.attachEvent('onload', loadSocialIDLoginWidget); | |
} | |
//]]> | |
</script> | |
<div id='socialid_login_container' style='display: inline-block; padding: 5px'></div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment