A PHP Error was encountered

Severity: Warning

Message: date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone.

Filename: libraries/Core.php

Line Number: 284

EE Cookies - EE Add-on

Want a Cookie? Nom Nom Nom.

EE Cookies

This plugin sets and retrieves cookie values with a tag rather than php scripting.

Installation

  1. EE 2: Add the folder /cookies/ to your ./system/expressionengine/third_party/ folder.
  2. EE 1.6: Add the file pi.cookies.php to your ./system/plugins/ folder.

Tags

{exp:cookie:store}
The cookie setter tag. Use it in combination with the parameters below to set and modify cookies. It require all three of the parameters below to be set.
{exp:cookie:retrieve}
This is the getter tag, it can retreave the value of a cookie. It's always used in combination with the name parameter.

Parameters

name=" "
Set the name of the cookie name="cookie_name"
value=" "
The value of the cookie being set value="the value to set"
seconds=" "
How many seconds would you like the cookie to last for? seconds="3600"

Examples

The following sets a cookie named mycookie with the value "EE rules!". The cookie will last for 1 hour (3600 seconds). Set the seconds to zero to set a cookie that does not expire.

{exp:cookie:store name="mycookie" value="EE rules!" seconds = "3600"}

To retrieve a cookie:

{exp:cookie:retrieve name="mycookie"}

This 1.6.x version of this plug in was originally developed by Eric Snyder