view tests/url.ur @ 770:c125df6fabfc

Runtime URL and MIME type filtering
author Adam Chlipala <>
date Sat, 02 May 2009 18:20:15 -0400
parents e28637743279
line wrap: on
line source
fun readersChoice r = return <xml><body>
  {case checkUrl r.Url of
       None => <xml>I can't do that, Dave.</xml>
     | Some url => <xml><a href={url}>Your pick, boss</a></xml>}

fun main () : transaction page = return <xml><body>
  <a href="">Learn</a>

  <form><textbox{#Url}/> <submit action={readersChoice}/></form>