Best practices for working with multiple Windows browsers and / or tabs

What is the best practice for handling multiple windows and / or tabs in a web application? What are the pros and cons of this approach?

I am not looking for an answer that indicates a specific solution for the platform. Best practice should be applied to all HTTP / HTML-based web applications, whether ASP, .NET, Java Servlets, Struts, JSF, etc.

Assumptions:

  • the application cannot prevent the user from opening a new window and / or tab

  • HTTP / HTML (how or if it is created by some structure does not matter). Not Flex, Flash, etc.

If the application tries to detect (possibly using the nonce method or another method) that a new window and / or tab has been opened and some error messages are displayed?

If the application allows a new window and / or tab, what are the pitfalls (forms for one) to view and how to handle them?

+3
source share
1 answer

I would say that the most important thing is to avoid the use of "long-term" mutable session data (data that will hang longer than just the instance needed to transfer data to the next page). This is the biggest problem I've seen with multiple tabs. What I like to do is store the data in the session, and then "serialize" this data on the page. When I need this data, I take it from the page and save it in the session. This prevents other users from changing other open pages.

, . , . , , , ( ) ( ).

+3

Source: https://habr.com/ru/post/1773053/


All Articles