Launching Janrain pop-up from an iFrame and redirecting the iFrame after login.

120 views
Skip to first unread message

Chris

unread,
Nov 9, 2011, 9:30:51 PM11/9/11
to rpx-dev...@googlegroups.com
We currently have an application where we run our app in a pop-up iFrame on our partner's website. We are now adding features that will require the partner's user to login to our website via Janrain from within our iFrame in order for us to track data specific to that user. 

We can launch the Janrain login pop-up from within our iFrame without any problems. The iFrames are nested properly. The login process also works properly. The problem we have is that after the login successfully completes, Janrain re-directs the underlying partner page (the one the browser is viewing) back to our site rather than redirecting our page that is loaded in the iFrame. We have tried some of the un-documented features mentioned in the forums, but those end up redirecting the small Janrain popup iFrame back to our site. So we can redirect the underlying page in the browser or the Janrain iFrame back to our site after a successful login, but we can not figure out how to redirect our iFrame that is "in the middle". Any ideas? 

Partner page loaded by browser -> launches our iFrame -> our iFrame launches the Janrain login iFrame. 
Goal: Redirect our iFrame after an successful login. (or just have the Janrain login box disappear)

Thanks, 
Chris

Nathan Ramsey

unread,
Dec 1, 2011, 8:54:14 PM12/1/11
to Janrain Developers
You should be able to use the client side sign-in as described here:
http://documentation.janrain.com/social-login-widget/user-s-guide/client-side-retrieval

The 10k' view is:
The popup window happens just the same
The page hosting the widget (in this case your iframe) isn't
redirected after the sign-in
Instead, an event is fire and the Javascript can go Ajax submit the
auth_info token
Then you can redirect your iframe as you please.
This sounds exactly like what you want.

The documentation is a little sketchy so by all means feel free to
follow up with additional questions.

Reply all
Reply to author
Forward
0 new messages