Copyright © 2007 Mochi Media, Inc.
Authors: Emad El-Haraty (emad@mochimedia.com).
header() = {Name::string(), Value::string()}
proplist() = [{Key::string(), Value::string()}]
cookie/2 | cookie(Key, Value, []). |
cookie/3 | Generate a cookie string based from the Key Value and Options Options should be a proplist of various cookie attributes to set returns a tuple {"Set-Cookie", string()}. |
parse_cookie/1 | Parse the value of a Cookie header, ignoring cookie attributes, and return a simple property list. |
test/0 | Run tests for mochiweb_cookies. |
cookie(Key::string(), Value::string()) -> header()
cookie(Key, Value, []).
cookie(Key::string(), Value::string(), Options::proplist()) -> header()
Generate a cookie string based from the Key Value and Options Options should be a proplist of various cookie attributes to set returns a tuple {"Set-Cookie", string()}. The option Max-Age (max_age) expects an integer indicating the number of seconds the cookie should expire in.
parse_cookie(Cookie::string()) -> [{K::string(), V::string()}]
Parse the value of a Cookie header, ignoring cookie attributes, and return a simple property list.
test() -> ok
Run tests for mochiweb_cookies.
Generated by EDoc, Aug 9 2007, 13:31:11.