Mercurial > urweb
view tests/cookie.ur @ 462:21bb5bbba2e9
Setting a cookie
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Thu, 06 Nov 2008 11:29:16 -0500 |
parents | f542bc3133dc |
children | bb27c7efcd90 |
line wrap: on
line source
cookie c : string fun main () : transaction page = setCookie c "Hi"; so <- requestHeader "Cookie"; case so of None => return <xml>No cookie</xml> | Some s => return <xml>Cookie: {[s]}</xml>