I am making a manual login flow with facebook without js sdk i have an iframe to get user approval it works fine and returns short-lived access token withn url but the problem when i want to get the url like iframe.src
it returns the src i provided not redirected and which contains facebooks response.The question is how i can get redirected current url of an iframe .
i tried
iframe.location.href
but it seems iframe doesnt have dom inside, and location is undefined.
I am making a manual login flow with facebook without js sdk i have an iframe to get user approval it works fine and returns short-lived access token withn url but the problem when i want to get the url like iframe.src
it returns the src i provided not redirected and which contains facebooks response.The question is how i can get redirected current url of an iframe .
i tried
iframe.location.href
but it seems iframe doesnt have dom inside, and location is undefined.
- Why not using the facebook javascript SDK ? Also, share code on how are you doing it through an iframe. – coding_idiot Commented Aug 4, 2015 at 17:57
- that's a weird way of doing it.. – Nitesh Oswal Commented Aug 4, 2015 at 18:06
-
Try
document.referrer
see stackoverflow./questions/3420004/… – Daniel Lizik Commented Aug 4, 2015 at 19:34 - nope it returns wrong value i tried already – nikoss Commented Aug 4, 2015 at 19:54
1 Answer
Reset to default 4I found out i can use frame.contentWindow.location
after it returns to my site
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745468243a4629013.html
评论列表(0条)