Q:

Open email link in an existing open window

We send out a confirmation email on completed registration. User need to click a link to confirm the registration, this link opens up a new window. Bog standard procedure... 
How can I get the new window to open up in the existing window (or close the old window)?
[Update, not sure if I was clear enough.]
When I click on the confirmation link I want it to open or replace the window I still have open from the registration process. 

A:

You can't control the user's email client (and this is a good thing), so you cannot direct how it opens links.
You could use a script on the "old" page (the one used to enter email address, profile details, etc.) to poll your server and do something once registration is confirmed.  If the user closes this page before that happens, e.g. opens another link on the site, this works well by not moving them where they don't expect.
The user would still have the registration page open, so simply put instructions on that along the lines of "email address confirmed, would you like to now 1) do this, 2) that, or 3) something else" (all links).

