There is no way to do what you want with cookies. Cookies are intentionally shared between browser windows. What you have to do is maintain state using data in the URL or hidden form fields. Not just a session ID in the URL, but the whole session data. That's the only way this can work.