Twitter Sign in page always showing

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-11 18:04:18

问题


I have implemented Sign in with Twitter on my web site using DotNetOpenAuth lib using asp.net mvc 3.

My problem is that every time the user click Sign-in with twitter it redirects him to a twitter page (even if he is already logged in to twitter).

I saw that sites like www.pinterest.com avoids this somehow.

How can I avoid the redirect to Twitter sign-in page if the user is already logged in to twitter?


回答1:


This is called Sign in with Twitter. Redirect users to https://api.twitter.com/oauth/authenticate?oauth_token=xyz instead of https://api.twitter.com/oauth/authorize?oauth_token=xyz. If the user is has an active session with twitter.com and has previously authorized the application they will silently be redirected to the callback url.



来源:https://stackoverflow.com/questions/10379853/twitter-sign-in-page-always-showing

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!