使用Javascript读取会话ID [英] Read Session Id using Javascript

查看:82
本文介绍了使用Javascript读取会话ID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以使用javascript读取浏览器会话ID?

Is it by any means possible to read the browser session id using javascript?

推荐答案

是的。会话ID通过URL( document.location.href )或通过cookie( document.cookie ),您可以检查是否存在会话ID。

Yes. As the session ID is either transported over the URL (document.location.href) or via a cookie (document.cookie), you could check both for the presence of a session ID.

这篇关于使用Javascript读取会话ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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