diff options
author | mensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f> | 2008-11-13 09:49:11 +0000 |
---|---|---|
committer | mensonge <mensonge@b3834d28-1941-0410-a4f8-b48e95affb8f> | 2008-11-13 09:49:11 +0000 |
commit | e44a7e37b6c7b5961adaffc62b9042b8d442938e (patch) | |
tree | 95b67c356e93163467db2451f2b8cce84ed5d582 /includes/js/dijit/tests/form/test_Form_onsubmit.html | |
parent | a62b9742ee5e28bcec6872d88f50f25b820914f6 (diff) | |
download | semanticscuttle-e44a7e37b6c7b5961adaffc62b9042b8d442938e.tar.gz semanticscuttle-e44a7e37b6c7b5961adaffc62b9042b8d442938e.tar.bz2 |
New feature: basic Ajax suggestion for tags and implementation of Dojo toolkit
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@151 b3834d28-1941-0410-a4f8-b48e95affb8f
Diffstat (limited to 'includes/js/dijit/tests/form/test_Form_onsubmit.html')
-rw-r--r-- | includes/js/dijit/tests/form/test_Form_onsubmit.html | 87 |
1 files changed, 87 insertions, 0 deletions
diff --git a/includes/js/dijit/tests/form/test_Form_onsubmit.html b/includes/js/dijit/tests/form/test_Form_onsubmit.html new file mode 100644 index 0000000..d8b43fa --- /dev/null +++ b/includes/js/dijit/tests/form/test_Form_onsubmit.html @@ -0,0 +1,87 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" + "http://www.w3.org/TR/html4/strict.dtd"> +<html> +<head> + + <title>Form unit test</title> + <style type="text/css"> + @import "../../../dojo/resources/dojo.css"; + @import "../css/dijitTests.css"; + </style> + <script type="text/javascript" src="../../../dojo/dojo.js" + djConfig="isDebug: true, parseOnLoad: true"></script> + <script type="text/javascript" src="../_testCommon.js"></script> + <script type="text/javascript"> + dojo.require("dojo.date"); + dojo.require("dijit.form.Form"); + dojo.require("dijit.layout.LayoutContainer"); + dojo.require("dijit.layout.ContentPane"); + dojo.require("dijit.form.ComboBox"); + dojo.require("dijit.form.CheckBox"); + dojo.require("dijit.form.DateTextBox"); + dojo.require("dijit.form.Button"); + dojo.require("dijit.form.MultiSelect"); + dojo.require("dijit.form.Textarea"); + dojo.require("dijit.form.SimpleTextarea"); + dojo.require("dijit.Editor"); + </script> +</head> +<body> + <h1>Form Widget Unit Test</h1> + <form dojoType="dijit.form.Form" id="myForm1" + encType="multipart/form-data" action="" method="GET" + onSubmit="dojo.stopEvent(arguments[0]);" + onReset="dojo.stopEvent(arguments[0]);"> + <h3>This form shouldn't submit, nor reset</h3> + <select name="plop.combo" dojoType="dijit.form.ComboBox"> + <option value="one">one</option> + <option value="two">two</option> + <option value="three">three</option> + </select> + <button dojoType=dijit.form.Button type="submit">Submit</button> + <button dojoType=dijit.form.Button type="reset">Reset</button> + </form> + + <form dojoType="dijit.form.Form" id="myForm2" + encType="multipart/form-data" action="" method="GET" + onSubmit="return false;" + onReset="return false;"> + <h3>This form shouldn't submit, nor reset</h3> + <select name="plop.combo" dojoType="dijit.form.ComboBox"> + <option value="one">one</option> + <option value="two">two</option> + <option value="three">three</option> + </select> + <button dojoType=dijit.form.Button type="submit">Submit</button> + <button dojoType=dijit.form.Button type="reset">Reset</button> + </form> + + <form dojoType="dijit.form.Form" id="myForm3" + encType="multipart/form-data" action="" method="GET" + onSubmit="return true;" + onReset="return true;"> + <h3>This form <em>should</em> submit and reset</h3> + <select name="plop.combo" dojoType="dijit.form.ComboBox"> + <option value="one">one</option> + <option value="two">two</option> + <option value="three">three</option> + </select> + <button dojoType=dijit.form.Button type="submit">Submit</button> + <button dojoType=dijit.form.Button type="reset">Reset</button> + </form> + + <form dojoType="dijit.form.Form" id="myForm4" + encType="multipart/form-data" action="" method="GET" + onSubmit="void(0)" + onReset="void(0)"> + <h3>This form <em>should</em> submit and reset</h3> + <select name="plop.combo" dojoType="dijit.form.ComboBox"> + <option value="one">one</option> + <option value="two">two</option> + <option value="three">three</option> + </select> + <button dojoType=dijit.form.Button type="submit">Submit</button> + <button dojoType=dijit.form.Button type="reset">Reset</button> + </form> +</body> +</html> |