Asp.net无Cookie的sessionId URL位置 [英] Asp.net cookieless sessionId url location

查看:320
本文介绍了Asp.net无Cookie的sessionId URL位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我工作的一个移动网站,我们不能依靠电话打到该网站有cookie支持上。我使用的会话cookie的选项,并想知道是否有指定的方式,其中在的SessionID被放在网址是什么?

下面是它看起来像现在:

  http://www.somesite.com/(S(qnxbzt45h2yxpr45tj3hpr45))/Default.aspx

有没有办法让的SessionID在URL的末尾?

  http://www.somesite.com/Default.aspx?S=qnxbzt45h2yxpr45tj3hpr45


解决方案

可以用SQL数据库,而不是你不存储用户会话?我不认为你可以改变的SessionID的位置,你可以尝试重写URL的,但我不知道怎么会影响到它的.Net的操控

编辑:我只记得在SQL选项仍然需要在客户端计算机上的Cookie所以不理我

I'm working on a mobile site where we can't rely on the phone hitting the site to have cookie support. I'm using the cookieless option for sessions and wondering if there's a way to specify where in the URL that the sessionId gets placed?

Here's what it looks like now:

http://www.somesite.com/(S(qnxbzt45h2yxpr45tj3hpr45))/Default.aspx

Is there a way to have the sessionId at the end of the url?

http://www.somesite.com/Default.aspx?S=qnxbzt45h2yxpr45tj3hpr45

解决方案

Can you not store user sessions using a Sql Database instead? I don't think you can change the sessionId position, you could try re-writing the url's but I'm not sure how that would affect .Net's handling of it

EDIT: I just remembered that the Sql option still requires a cookie on the client machine so ignore me

这篇关于Asp.net无Cookie的sessionId URL位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆