开发者

how to get url endpoint openid provider

开发者 https://www.devze.com 2023-01-07 02:17 出处:网络
how to get end point u开发者_运维问答rl of a openid provider likefor google if we get from https://www.google.com/accounts/o8/id or for yahoo it is http://me.yahoo.com.Similarly , for others how to fi

how to get end point u开发者_运维问答rl of a openid provider like for google if we get from https://www.google.com/accounts/o8/id or for yahoo it is http://me.yahoo.com .Similarly , for others how to find this information.


U can have something like this in a js file.. var defaultProviders = { google: { name: 'Google', url: 'https://www.google.com/accounts/o8/id', hasLargeIcon: true }, yahoo: { name: 'Yahoo', url: 'http://me.yahoo.com/', hasLargeIcon: true }, aol: { name: 'AOL', label: 'Enter your AOL screenname:', url: 'http://openid.aol.com/{username}', hasLargeIcon: true }, myopenid: { name: 'MyOpenID', label: 'Enter your MyOpenID username:', url: 'http://{username}.myopenid.com/', hasLargeIcon: true }, openid: { name: 'OpenID', url: 'http://', hasLargeIcon: true }, livejournal: { name: 'LiveJournal', label: 'Enter your Livejournal username:', url: 'http://{username}.livejournal.com/', hasLargeIcon: false }, wordpress: { name: 'Wordpress', label: 'Enter your Wordpress.com username:', url: 'http://{username}.wordpress.com/', hasLargeIcon: false }, blogger: { name: 'Blogger', label: 'Enter your Blogger account:', url: 'http://{username}.blogspot.com/', hasLargeIcon: false }, verisign: { name: 'Verisign', label: 'Enter your Verisign username:', url: 'http://{username}.pip.verisignlabs.com/', hasLargeIcon: false }, claimid: { name: 'ClaimID', label: 'Enter your ClaimID username:', url: 'http://openid.claimid.com/{username}', hasLargeIcon: false }, clickpass: { name: 'ClickPass', label: 'Enter your ClickPass username:', url: 'http://clickpass.com/public/{username}', hasLargeIcon: false } };

Than once username is available u can use following code to create complete URL... `function (event) { var cancel = true; var val = $('input[type=text]', username).val(); if (val.length > 0) { var pvd = providers[selectedId]; if (pvd) { _setLoading(true, true); var url = pvd.url.replace('{username}', val); _setOpenIdUrl(url); _setCookie(selectedId); alert("URL is : "+url);
input.get()[0].form.submit(); } } if (cancel) { event.preventDefault(); }
};' That will work most of the time....


Go to the web site in question and look through their docs. There's no authoritative or complete list of OP Identifiers.

0

精彩评论

暂无评论...
验证码 换一张
取 消