'How open same page on diffrent tab on browser with different value
I'm on develop a website using JSF, I got a problem on page that contain model Id, when I tried to open a same page twice on different tab browser, the value is same. How to set Id on every page to be able to show the right values ? or maybe What the name of the method ?. Thank You
Solution 1:[1]
Different browser tabs share allways a session. If you want to have local tab data, you need to identify separate browser tabs.
I did it this way:
- window.name is the only browser object with different memory per tab I found
- use window.name to hold the tab-id
- the browser is responsible for a generation of a uniq tab id if window.name is empty
- the generated tab-id is written in window.name
- the tab-id has to be in every url of the application
- a view scoped bean fetches (early) this tab-id and provides a per tab memory, hold by a session bean per tab-id
- use the tab memory instead of session memory
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Holger |
