view select.ur @ 1:4d8165e8f89a

Some help with building forms
author Adam Chlipala <adam@chlipala.net>
date Thu, 06 Jan 2011 16:45:47 -0500
parents
children
line wrap: on
line source
fun crender r =
    <xml><cselect source={r.Selected}>
      {List.mapX (fn r' => <xml><coption value={r'.Key}>{[r'.Display]}</coption></xml>) r.Choices}
    </cselect></xml>

fun crender' r =
    <xml><cselect source={r.Selected}>
      {List.mapX (fn s => <xml><coption>{[s]}</coption></xml>) r.Choices}
    </cselect></xml>