comparison src/monoize.sml @ 1463:607657eb2865

Properly handle form textboxes that have sources
author Adam Chlipala <adam@chlipala.net>
date Sun, 29 May 2011 12:44:31 -0400
parents 541673c3161d
children e2d7bd41f527
comparison
equal deleted inserted replaced
1462:c12ceb891350 1463:607657eb2865
2735 (L.ECApp ( 2735 (L.ECApp (
2736 (L.ECApp ( 2736 (L.ECApp (
2737 (L.EFfi ("Basis", "sql_nfunc"), _), 2737 (L.EFfi ("Basis", "sql_nfunc"), _),
2738 _), _), 2738 _), _),
2739 _), _), 2739 _), _),
2740 _), _), 2740 _), _),
2741 _) => 2741 _) =>
2742 let 2742 let
2743 val s = (L'.TFfi ("Basis", "string"), loc) 2743 val s = (L'.TFfi ("Basis", "string"), loc)
2744 fun sc s = (L'.EPrim (Prim.String s), loc) 2744 fun sc s = (L'.EPrim (Prim.String s), loc)
2745 in 2745 in
2746 ((L'.EAbs ("s", s, s, (L'.ERel 0, loc)), loc), 2746 ((L'.EAbs ("s", s, s, (L'.ERel 0, loc)), loc),
3256 loc)), loc), fm) 3256 loc)), loc), fm)
3257 end 3257 end
3258 | SOME (_, src, _) => 3258 | SOME (_, src, _) =>
3259 (strcat [str "<script type=\"text/javascript\">inp(exec(", 3259 (strcat [str "<script type=\"text/javascript\">inp(exec(",
3260 (L'.EJavaScript (L'.Script, src), loc), 3260 (L'.EJavaScript (L'.Script, src), loc),
3261 str "))</script>"], 3261 str "), \"",
3262 str name,
3263 str "\")</script>"],
3262 fm)) 3264 fm))
3263 | _ => (Print.prefaces "Targs" (map (fn t => ("T", CorePrint.p_con env t)) targs); 3265 | _ => (Print.prefaces "Targs" (map (fn t => ("T", CorePrint.p_con env t)) targs);
3264 raise Fail "No name passed to textbox tag")) 3266 raise Fail "No name passed to textbox tag"))
3265 | "password" => input "password" 3267 | "password" => input "password"
3266 | "textarea" => 3268 | "textarea" =>