常见问题主题 - 如果网页浏览器接受cookie,我如何在javascript中看到? [英] FAQ Topic - How can I see in javascript if a web browser accepts cookies?

查看:56
本文介绍了常见问题主题 - 如果网页浏览器接受cookie,我如何在javascript中看到?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

----------------------------------------------- ------------------------

常见问题解答主题 - 如果网页浏览器接受cookie,我如何在javascript中看到? />
-------------------------------------------- ---------------------------


写一个cookie,读回来然后检查一下这是一样的。

http:// www.w3schools.com/js/js_cookies.asp


附加说明:

http://www.jibbering.com/faq/faq_notes/cookies.html

===

这样的发布每天自动发送一次。他们的b
目标是回答重复的问题,并将内容提供给社区进行持续评估/改进。完整的

comp.lang.javascript常见问题解答位于 http:/ /www.jibbering.com/faq/

FAQ工作人员是一群志愿者。

-----------------------------------------------------------------------
FAQ Topic - How can I see in javascript if a web browser accepts cookies?
-----------------------------------------------------------------------

Writing a cookie, reading it back and checking if it''s the same.

http://www.w3schools.com/js/js_cookies.asp

Additional Notes:

http://www.jibbering.com/faq/faq_notes/cookies.html
===
Postings such as this are automatically sent once a day. Their
goal is to answer repeated questions, and to offer the content to
the community for continuous evaluation/improvement. The complete
comp.lang.javascript FAQ is at http://www.jibbering.com/faq/.
The FAQ workers are a group of volunteers.

推荐答案

FAQ server写道:
FAQ server wrote:

------------------------ -----------------------------------------------

常见问题解答主题 - 如果网页浏览器接受cookie,我如何在javascript中查看?

--------------------- --------------------------------------------------


写一个cookie,读回来并检查它是否相同。
-----------------------------------------------------------------------
FAQ Topic - How can I see in javascript if a web browser accepts cookies?
-----------------------------------------------------------------------

Writing a cookie, reading it back and checking if it''s the same.



你不能吗?只需检查window.navigator.cookieEnabled?


Andrew Poulos

Can''t you just check window.navigator.cookieEnabled?

Andrew Poulos


Andrew Poulos于2006年12月11日在comp.lang.javascript上写道
Andrew Poulos wrote on 11 dec 2006 in comp.lang.javascript:

FAQ server写道:
FAQ server wrote:

> ------------------------------------------- ---------------------------
- 常见问题解答主题 - 如果网页浏览器接受
,我如何在javascript中看到cookies?
-------------------------------------------- --------------------------
-

写一个cookie,读回来并检查它这是一样的。
>----------------------------------------------------------------------
- FAQ Topic - How can I see in javascript if a web browser accepts
cookies?
----------------------------------------------------------------------
-

Writing a cookie, reading it back and checking if it''s the same.



你能不能检查一下window.navigator.cookieEnabled?


Can''t you just check window.navigator.cookieEnabled?



是否有任何浏览器没有实现此功能? [ie和ff似乎没问题]


-

Evertjan。

荷兰。

(请将我的电子邮件地址中的x'变为点数)

Are there any browsers not implementing this? [ie and ff seem ok]

--
Evertjan.
The Netherlands.
(Please change the x''es to dots in my emailaddress)


Evertjan。写道:
Evertjan. wrote:

Andrew Poulos于2006年12月11日在comp.lang.javascript中写道

> FAQ服务器写道:
>FAQ server wrote:

>> ------------------- -------------------------------------------------- -
- 常见问题解答主题 - 如果网页浏览器接受
Cookie,如何在javascript中查看?
-------------------- --------------------------------------------------
-

写一个cookie,读回来并检查它是否相同。
>>----------------------------------------------------------------------
- FAQ Topic - How can I see in javascript if a web browser accepts
cookies?
----------------------------------------------------------------------
-

Writing a cookie, reading it back and checking if it''s the same.


你不能只检查窗口.navigator.cookieEnabled?


Can''t you just check window.navigator.cookieEnabled?



是否有任何浏览器没有实现此功能? [ie和ff似乎没问题]


Are there any browsers not implementing this? [ie and ff seem ok]



没关系,因为测试没有考虑到

账户内容插入/重写代理的动作可能会重新编写引用cookie的代码,以便它不会(即

更改所有出现的字符序列' 'cookie''进入

别的东西)。


Richard。

It would not matter is there were not as that test doesn''t take into
account the actions of content inserting/re-writing proxies which may
re-write the code that references cookies so that it does not (i.e.
change all occurrences of the character sequence ''cookie'' into
something else).

Richard.


这篇关于常见问题主题 - 如果网页浏览器接受cookie,我如何在javascript中看到?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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