Reputation: 635
I want to parse the access_token from the url which facebook login will redirect to. What I got is the following URL and I'd like to know how to parse it in Google App Engine (GAE).
http://localhost:8080/web/#access_token=aaaa&expires_in=5423
I tried using get
, get_all
but it returns nothing.
Upvotes: 1
Views: 419
Reputation: 1126
import urlparse
access_token = urlparse.parse_qs(urlparse.urlsplit(url).fragment).get('access_token')
Upvotes: 1