1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-03 12:58:35 +03:00
samba-mirror/swat/esptest/exception.esp
Andrew Tridgell 1bf7a917b2 r7094: use the Form() object in a few more places
(This used to be commit 9b8546f92179dba826e7ca5ed009b24486ef7a2c)
2007-10-10 13:17:15 -05:00

31 lines
575 B
Plaintext

<% page_header("columns", "ESP Exception test"); %>
<h1>Samba4 exception test</h1>
<%
var f = Form("ExceptionTest", 0, 2);
f.submit[0] = "Generate Exception";
f.submit[1] = "No Exception";
display_form(f);
if (request['REQUEST_METHOD'] == "POST") {
function TestFunction(arg1, arg2) {
return "OK";
}
if (form['submit'] == "Generate Exception") {
write("I expect you to die Mr Bond!<br>\n");
TestFunction("foo");
} else {
write("no exception<br>\n");
TestFunction("foo", "bar");
}
}
%>
and here is some filler text ...
<% page_footer(); %>