IntelliJ Java IDE
The moose likes JSP and the fly likes Creating a new session in new browser window Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSP
Reply Bookmark "Creating a new session in new browser window" Watch "Creating a new session in new browser window" New topic
Author

Creating a new session in new browser window

kul karni
Greenhorn

Joined: Nov 19, 2011
Posts: 12

Hi Guyz,

I want to disallow the same session to be shared across multiple TABS of a single browser WINDOW.
I mean to say that, if I have 2 login ids for 2 accounts, then I should be able to login to both the accounts
in multiple TABS in the same browser WINDOW(and not another window).


Thank you.
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 11862
I don't think there is any way to do that that will work in all browsers.

Time to stop and think!

Why not create a class to hold all variables associated with a single account and store an instance for each account in the single session. In order to select the correct one, you will need to have some way of identifying which tab generated a request - hidden variable in a Form would be my choice.

Bill

Java Resources at www.wbrogden.com
Tarun Bolla
Ranch Hand

Joined: Jun 20, 2011
Posts: 85
I think URL rewriting works too...passing a unique identifier generated at server in every url ... so that you can identify the session for each request
 
 
subject: Creating a new session in new browser window
 
Threads others viewed
session issue with multi tabs in a browser
session issues with multi tabs in a browser
session problem
Firefox session reuse causing problems with backing beans
Detecting Multiple Page Opened in Browser
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture