Thanks for the reply. My callback URL is a servlet. I can get all the
session info there.
How do I then call a javascript to close the child window and forward
the parent window?
I am not sure how do I go to client side from the servlet.


On Mar 15, 1:35 pm, Michael Steuer <mste...@gmail.com> wrote:
> There's better ways of doing this actually, that doesn't require polling of
> any kind...
>
> In your pop up, when Twitter redirects to your callback URL:
>
> - process the Oauth tokens etc so that your user's session is authenticated
> - set the parents window location to whereever it needs to go (logged in
> view of your app), using window.opener.location.href = "whatever"
> - close the popup (window.close)
>
> On 3/15/10 5:58 AM, "Taylor Singletary" <taylorsinglet...@twitter.com>
> wrote:
>
> > You can't accomplish it exactly the way you want to, but you can do this:
>
> > 1) Set the OAuth callback to a URL that's still on your domain,
> > something specific that's purpose is only to collect the callback
> > details and quickly return a 200 status.
> > 2) In your parent window, occasionally poll the status of the child
> > window -- when it's on Twitter.com you won't have access to its
> > window.location.
> > 3) When the window.location is on your callback URL and the same
> > domain as the parent window, you'll be able to close the pop-up window
> > and then change the state of the originating window in turn.
>
> > Taylor Singletary
> > Developer Advocate, Twitter
> >http://twitter.com/episod
>
> > On Mon, Mar 15, 2010 at 6:50 AM, deb123 <debolina....@gmail.com> wrote:
> >> I am trying to open the "Accept/Deny" window in a new window. I want
> >> the callback to come back to the parent window. If I use window.open,
> >> I get the pop up but the callback comes back to the child window. I
> >> want the child window to close when the use hits the Accept or Deny
> >> and the callback to come to the parent window.
> >> How do I make this happen?
> >> Thanks,
> >> D

Reply via email to