Skip to content

Set Cookie#


Description#

Set and output cookies

Snippet#

 <mvt:assign name="g.expires"       value="s.time_t + (60 * 60 * 24 * 5)" /> // 5 days from today
<mvt:assign name="g.cookie_name"   value="'mycookie'" />
<mvt:assign name="g.cookie_value"  value="'hello world'" />

<mvt:do file="g.module_library_utilities" name="g.null" value="SetCookie(g.Output_Cookies, g.cookie_name, g.cookie_value , g.cookiedomain , g.expires, g.cookiepath, 0 )" />
<mvt:do file="g.module_library_utilities" name="g.null" value="OutputCookies( g.Output_Cookies )" />

Functions Used#

  • SetCookie
  • OutputCookies