view tests/rpcList2.ur @ 2057:f4a6ccb7937f

Allow Body tags inside cformTags This is required by Bootstrap. For example, see http://getbootstrap.com/components/#alerts-dismissible
author Sergey Mironov <grrwlf@gmail.com>
date Sun, 17 Aug 2014 18:28:37 +0000
parents 553a5cc3a4b5
children
line wrap: on
line source
fun showList l = case l of
    [] => "[]"
  | h :: t => strcat (strcat (show h) " :: ") (showList t)

fun rpcFunc l : transaction string =
  case l of h :: _ => return (showList h) | [] => return "[]"

fun main () : transaction page = return <xml><body>
  <button onclick={
    s <- rpc (rpcFunc  (("foo" :: []) :: []));
    alert s
  }/>
  </body></xml>