Mercurial > urweb
annotate tests/form.ur @ 1779:7095e1b7240b
HTTP daemons now take '-a' option to set IP address to listen on
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Sat, 23 Jun 2012 09:46:40 -0400 |
parents | 71bafe66dbe1 |
children |
rev | line source |
---|---|
adamc@142 | 1 val handler = fn r => <html><body> |
adamc@142 | 2 <li> Name: {cdata r.Nam}</li> |
adamc@142 | 3 <li> Word: {cdata r.Word}</li> |
adamc@142 | 4 </body></html> |
adamc@142 | 5 |
adamc@141 | 6 val main : unit -> page = fn () => <html><body> |
adamc@141 | 7 <lform> |
adamc@141 | 8 Name: <textbox{#Nam} /><br/> |
adamc@142 | 9 Word: <textbox{#Word} /><br/> |
adamc@142 | 10 |
adamc@142 | 11 <submit action={handler}/> |
adamc@141 | 12 </lform> |
adamc@141 | 13 </body></html> |