HTML中的会话管理 [英] Session Management in html

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

问题描述

我需要在服务器中的每个html页面中管理会话.

Hi I need to manage session in every html page in my server

推荐答案

无法使用服务器上的Javascript或HTML管理会话.通过服务器端脚本语言(asp.net,php,JSP等)进行管理
只有您可以使用JS来将cookie存储在客户端上
并使用HTML 5可以在客户端使用本地存储或SQL存储
It is not possible to manage session using Javascript or HTML with the server Session can be manage by the Server side scripting language(asp.net,php,JSP etc.)
only you can do with JS is storing cookie on client end
and with HTML 5 you can use local storage or SQL storage on client side




如您所说,您需要打开新的html窗口.在这种情况下,您可能可以通过QueryString获得会话值.如果您的Session内容不多,则可以使用QueryString传递该值,并且可以在html页中读取querystring.

示例QueryString. [
Hi,

As you said that you need to open new html window. in this case probably you can get session value by QueryString. if your content of Session is not more then you can pass that value using QueryString and you can read querystring in html page.

Example of passign QueryString.[^]

Hope now its easy for you to implement

Thanks
-Amit Gajjar


这篇关于HTML中的会话管理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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