1.0.0 • Published 8 years ago

fg-cookie v1.0.0

Weekly downloads
41
License
MIT
Repository
github
Last release
8 years ago

cookie function

Get, set, or forget cookies.

  • c2014 @scottjehl, Filament Group, Inc.
  • Licensed MIT

Based on code examples found at:

API

To get a cookie, pass only a name. It'll return null if undefined.

cookie( "foo" );

To set a cookie, pass a name, a string value, and optionally a number of days until the cookie expires

cookie( "foo", "bar", 5 );

To delete a cookie, pass a name, and a false value

cookie( "foo", false );