Trailing characters in URL after Facebook Login

北战南征 提交于 2019-12-20 05:50:35

问题


I am going through the facebook authentication process to log my users into my site. Once a user is logged in I redirect to the profile page using:

resp.sendRedirect("/l/profile");

But when I get to the profile page, the URL ends /profile#_=_

This seems to be at the end of the URL redirected by facebook when it returns a code. Why is it sticking around, how do I get rid of it?


回答1:


I'm guessing it's a byproduct of new feature called "Authenticated Referrals" whereby they add a valid accessToken to the end of the url as either an #anchor or ?param (depending on whether you're reading it client- or server-side). You can read more about it here: http://developers.facebook.com/docs/opengraph/authentication/

At any rate, because it's appended Facebook-side, you'll have to file a bug with them to fix it, although at the moment the tracker seems to be down for me.



来源:https://stackoverflow.com/questions/9123807/trailing-characters-in-url-after-facebook-login

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