1 User clicks on a link 2 Popup window opens. 3 XXXXX - See below. 4 Popup disappears 5 original window reloads.
So I've got the link to pop open the window (1, 2). I've got the code that will work to close the child window and reload the parent (4, 5).
Here is the code:
I suppose what's happening is, the result of the form submission is "some other page" and the 'opener' object is not maintained. I thought it would be, because I thought it was a 'window' attribute.
Yeah, off the top of my head I would have expected opener to remain valid since you are only swapping out the document. Oh well... How about if you submit your form into an invisible iframe? That way the original page, with opener intact would remain across the submission. The response to the submission could alert its parent that it's done, which would trigger the close and reload of the opener. A bit messy, but may work for you.
I was popping open the child window from the parent's domain, but the response from the servlet came from a subdomain. Since the subdomain was an alias anyways, I set them both the same, and now it works.