Cookies in Windows 8 WinJS

2019-06-13 17:58发布

问题:

How can i enable for the IE10 store the cookies?

Some internet services (Facebook Dialogs for example) pass variables this way which you need to use them in further request, but IE10 dont allow cookies.

What i'm trying to do is login at facebook with "Windows.Security.Authentication.Web.WebAuthenticationBroker", get the token, and then open the feed dialog... when i try to open the feed dialog, i receive an error, because the page have no cookies...

回答1:

If your question is about WinRT Applications written using JavaScript/HTML/CSS then you don't have the notion of cookies, because this is not IE10 but instead it's the IE10 HTML rendering engine - Trident, and IE10 JS engine - Chakra. You have AppData (Local state, Temp state, Roaming state) in Windows Store Apps which you can use to store any data you want. Here's a guide how to access the Local State.

If the question is really about IE10 then I assure you IE10 supports cookies if the user has cookies enabled.