Path error when enabling sessionstate cookieless = true

M

Morten H.

Hey,

I have a problem on my server. WHen I activate cookieless sessionstate
I can only execute aspx pages. When the server tries to find an image
in a subfolder eg. http://mysite/(gklffgfgdsg85t6583)/image/top.gif
its not found. The same goes for javascripts ect. if I remove the
sessionid (http://mysite/image/top.gif) the image is found as usual.

This is only a problem on one of our servers, and I suspect that an
update has caused this, but I cant seem to find the error.

Any ideas ?
 
G

George Ter-Saakov

Browser does not know that (gklffgfgdsg85t6583)
is a session id so whenever it sees reference to image/top.gif (or any other
file) it sends a request appending the full path to it.

Only requests for aspx files are mapped to ASP.NET engine and ASP.NET has an
ability to strip out the session id.
Requests for gif, jpg, html, txt,.... are processed by IIS server and IIS
server on WIN2K is totaly unaware of ASP.NET so it can not strip out session
id. I heard that in Win2003 IIS more integrated with ASP.NET and it could
work ( Do not know for sure ).


The solution is to use absolute urls instead of relative urls.

So image/top.gif you shoud be replaced with /image/top.gif (notice first
/ ).

You can use VS to do search and replace in all files ('image' to '/image').

George.
 
M

Morten Hoegh

George,

That was not the solution to the problem ... sorry.
I found a fix for it at microsoft. It seems that the regkey for my
server was messed up. Running the aspnet_regiis.exe -i solved the
problem. It has nothing to do with the browser. The browser holds the
session id inthe URL. The IIS reads the Session ID from the URL and maps
the files to the correct source, mine didn't but the fix took care of
that.

Hope this helps other people as I had a VERY hard time finding the
solution.



Cheers ! (and Merry Christmas)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top