Tutorial :ASP.Net SessionID keeps getting lost



Question:

My asp.net application works fine when launched from its own browser, but when its launched from another web application (sharepoint webpart) using window.open it works until the user clicks and posts back, then the session is lost.

I think its related to cookies, because when I set the session state to be cookieless everything works fine.

Why does the sesssionid get lost in the NEW application when launching the app using window.open? I would like each application to have its own session cookie, I've tried setting the name of the cookie but the same thing happens, on the first post back the sessionid is lost??

Please help?


Solution:1

Sharepoint manages it's own session. Sessions are tied to applications (URI). You would need to share some sort of login token between applications.

check out:

http://forums.asp.net/t/1335229.aspx

http://forums.asp.net/p/1356006/2781938.aspx


Solution:2

What browser are you using?

IE6 has this exact issue, possibly newer versions as well.

Refer to Microsoft Support


Solution:3

drop window.open(). use links with tarket="blank". if you need to call them from JS just do link.click() on it.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »