view tests/radio.ur @ 1822:8bc16ff91d32

Edward Z. Yang's patch to avoid repeating linker arguments
author Adam Chlipala <adam@chlipala.net>
date Wed, 19 Sep 2012 14:20:47 -0400
parents a1a1d66aebac
children
line wrap: on
line source
fun handler x = return <xml><body>
  You entered: {[case x.A of
                     None => "nothing at all"
                   | Some v => v]}
</body></xml>

fun main () = return <xml><body>
  <form>
    <radio{#A}>
      <li><radioOption value="A"/>A</li>
      <li><radioOption value="B"/>B</li>
    </radio>
    <submit action={handler}/>
  </form>
</body></xml>