Clear Up
SharpKit Reference

CookieProvider Class

A Provider implementation which saves and retrieves state via cookies. The CookieProvider supports the usual cookie options, such as:

  • path
  • expires
  • domain
  • secure

Example:

  
var cp = Ext.create('Ext.state.CookieProvider', {
            path: "/cgi-bin/",
            expires: new Date(new Date().getTime()+(1000*60*60*24*30)), //30 days
            domain: "sencha.com"
            });
            Ext.state.Manager.setProvider(cp);
            

Namespace: Ext.state

Base Interfaces

Constructors

Fields

Name Description
domain The domain to save the cookie for. Note that you cannot specify a different domain than your page is on, but you can specify a sub-domain, or simply the domain itself like 'sencha.com' to include all sub-domains if you need to access cookies across different sub-domains. Defaults to null which uses the same domain the page is running on including the 'www' like 'www.sencha.com'.
expires The cookie expiration date. Defaults to 7 days from now.
path The path for which the cookie is active. Defaults to root '/' which makes it active for all pages in the site.
secure True if the site is using SSL Defaults to: false
© Copyright 2005-2011 SharpKit. All rights reserved.