本文介绍了Cookie.HTTPOnly在传统的ASP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

如何在一个页面中的所有Cookie变量设置为中HTTPOnly在ASP?

How to set all the cookie variables in a page to HTTPOnly in ASP?

推荐答案

我怕用Response.Cookies集合设置时,仅Http将无法正常工作(它已经让我慢慢地疯了!)。
如VBScript(嗯,至少在服务器上我测试的)将字符连接code中的分号。

I'm afraid using the Response.Cookies collection will not work when setting HttpOnly (it's been driving me slowly mad!).As vbscript (well at least on the server i'm testing on) will character encode the semicolon.

相反,手动添加自己的头,例如:

Instead, add the header manually yourself, for example:

Response.AddHeader "Set-Cookie", "YourCookieName=YourCookieValue; path=/; HttpOnly"

有一个类似的帖子计算器上叫:How你究竟在ASP经典配置的HttpOnly饼干?

There is a similar post on stackoverflow called: How exactly do you configure httpOnly Cookies in ASP Classic?

这篇关于Cookie.HTTPOnly在传统的ASP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-08 10:02