developer documentation r21358

fm.cookies

The fm.cookies package contains some functions helping you with setting/getting cookie values.

fm.cookies.getCookie(name)

This function is used to retrieve a cookie.

Example

alert(fm.cookies.getCookie('SABRE_ID'));

fm.cookies.setCookie(name,value,expiry)

This function sets a new (session) cookie.It accepts 3 arguments:

The third argument may be omitted, in which case this cookie will be a sessioncookie; it will be destroyed after a user closes their browser.

Example

fm.cookies.setCookie('firstname','sharpie', 30);
<< 9.1 fm.api 9.3 fm.flash >>