Commit 4e7c11f0c925c77dcabee223a01626a5289722d6
1 parent
03e5f9d1
Fix IE double submit bug: now the generated javascript is dependent of button as…
…pect for full backward compatibility.
Showing
1 changed file
with
5 additions
and
3 deletions
Show diff stats
calexium_lib/web/CXM_making_a_web_site.anubis
| ... | ... | @@ -2827,6 +2827,7 @@ define URL_or_JavaScript |
| 2827 | 2827 | format_action |
| 2828 | 2828 | ( |
| 2829 | 2829 | String the_url, |
| 2830 | + Actioner_Aspect aspect, | |
| 2830 | 2831 | Maybe(String) mb_id, |
| 2831 | 2832 | Maybe(String) mb_form_name |
| 2832 | 2833 | ) = |
| ... | ... | @@ -2847,8 +2848,9 @@ define URL_or_JavaScript |
| 2847 | 2848 | "function ", fn_name, "() {\n", |
| 2848 | 2849 | " var fa = document.forms.f",form_name,";\n", |
| 2849 | 2850 | " var u = \"",the_url,"\";\n", |
| 2850 | - " fa.action = u; }\n", | |
| 2851 | -// " fa.submit(); }\n", | |
| 2851 | + " fa.action = u;", | |
| 2852 | + if aspect is submit(_, _) then " }\n" | |
| 2853 | + else "\n fa.submit(); }\n", | |
| 2852 | 2854 | "</script>\n" |
| 2853 | 2855 | ], |
| 2854 | 2856 | [fn_name,"();"] |
| ... | ... | @@ -3120,7 +3122,7 @@ define Printable_tree |
| 3120 | 3122 | if cinfo is info(common_name,http_port,https_port,site_dir,secret) then |
| 3121 | 3123 | with url = make_actioner_url(cinfo,connection,target, |
| 3122 | 3124 | state_name,action_name,extra_ops,is_https), |
| 3123 | - with action = format_action(url, extract_id(aspect), mb_form_name), | |
| 3125 | + with action = format_action(url, aspect, extract_id(aspect), mb_form_name), | |
| 3124 | 3126 | if aspect is |
| 3125 | 3127 | { |
| 3126 | 3128 | ... | ... |