本文介绍了停止在浏览器的多个选项卡之间共享会话状态的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

场景:
默认情况下,所有浏览器在多个选项卡之间共享会话状态.因此,如果您登录了具有特定站点的一个选项卡并在新选项卡中打开了同一站点的内部链接,则不必担心再次登录.它会自动将您声明为登录用户.

例如,如果我打开google并登录到google.com.现在,我在同一浏览器中打开新标签页,然后输入gmail.com,它将自动登录并重定向到Google Mail,在此步骤中,它不会要求我再次登录.

要求:

如果我是站点中客户帐户的管理员.现在,我要访问客户"ABC"的帐户,然后打开新标签并访问客户"PQR"的帐户.该会话现在正在保存有关客户"PQR"的信息,并认为我正在处理客户"PQR".现在,在处理客户"PQR"之后,我回到客户"ABC"(选项卡)并开始对其进行编辑.实际上,根据会话信息,再次假设我正在编辑客户"PQR",问题从这里开始(数据差异).

因此,请让我知道如何为浏览器的每个实例创建唯一的会话?

解决方案



Scenario:
By default all browsers share session state between multiple tabs. So if you logged into one tab with particular site and open internal link of the same site in new tab, you need not to worry to login again. It will automatically declare you as logged in user.

For example, if I open google and login to google.com. Now I open new tab in the same browser and type gmail.com then it will automatically logged in me and redirect to google mail, here at this step it will not ask me to log in again.

Requirements:

If I am administrator of customer accounts in site. Now I am accessing account of customer "ABC" and then open new tab and access account of customer "PQR". The session is now holding information for customer "PQR" and thinks that I am working on customer "PQR". Now after working on customer "PQR", I am coming back to customer "ABC" (tab) and start editing it. Actually according to session information it is assuming again that I am editing customer "PQR" and the problem starts here(data discrepancy).

So please let me know how i can create a unique session for every instance of browser ?

解决方案




这篇关于停止在浏览器的多个选项卡之间共享会话状态的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

06-25 22:38