locked
Session Problem RRS feed

  • Question

  • User1224235962 posted

    Hi All,

    I am using session("uid") to store Employee Id now if two diffrent user are opening their login in same broswer with diffrent tab session("uid") is storing last user id both the place

    Please help me to prevent this

    Monday, October 3, 2011 5:04 PM

Answers

  • User-8475372 posted

    This can be avoided by having this in your web.config

    <system.web>
    <sessionState mode="InProc" cookieless="UseUri">
    </sessionState>
    </system.web>
    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, October 11, 2011 3:29 AM

All replies

  • User465171450 posted

    Cookies are shared across a browser session so the session cookie that is on one tab, will be the same on another. Unfortunately, this isn't something you can really do effectively without using cookieless sessions, which can be hackable, or they have to use a completely different browser to avoid sharing cookies. Using two instances of the same browser also won't help as they too share their cookie collection.

    Monday, October 3, 2011 5:42 PM
  • User2063778947 posted

    Hi,

    Using Form Authentication you can solve this issuse.

    Regards,

      Rex

    Thursday, October 6, 2011 3:20 AM
  • User-1885946167 posted

    you can't solve this if you wanna keep the authentication method unchanged..even google, yahoo etc.. behaves the same way..

    Tuesday, October 11, 2011 12:04 AM
  • User1099482290 posted

    That is common problem there are two solutions

    If you wish to override this behavior and get a new session, you can chose "File – New Session" from IE menu

    or

    check following link

    http://geekswithblogs.net/ranganh/archive/2009/04/17/asp.net-session-state-shared-between-ie-tabs-and-ie8.aspx

     

    Tuesday, October 11, 2011 1:39 AM
  • User-8475372 posted

    This can be avoided by having this in your web.config

    <system.web>
    <sessionState mode="InProc" cookieless="UseUri">
    </sessionState>
    </system.web>
    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, October 11, 2011 3:29 AM