Dojo Dijit and HTML5 in Real world applications/Dijit/dijit.form.Form: Difference between revisions

From PMISwiki
Jump to navigation Jump to search
(Created page with "==dijit.form.Form== ==Tips and tricks== If your dijit.form.Form is not sent to the server it is likely that you forgot to specify the data-dojo-props: <syntaxhighlight lang="ht...")
 
 
(No difference)

Latest revision as of 21:58, 16 September 2011

dijit.form.Form

Tips and tricks

If your dijit.form.Form is not sent to the server it is likely that you forgot to specify the data-dojo-props:

    <form id="myForm" action="myServerFile.php" method="post" name="myForm"
                data-dojo-type="dijit.form.Form"
                data-dojo-props=" name:  'myForm',
                                  action:'myServerFile.php', 
                                  method:'post'">
    <!-- form elements -->
    </form>

Some IE versions has difficulties with dijit forms, therefore, it is advisable to use the <div> tag instead:

    <div id="myForm" action="myServerFile.php" method="post" name="myForm"
                data-dojo-type="dijit.form.Form"
                data-dojo-props=" name:  'myForm',
                                  action:'myServerFile.php', 
                                  method:'post'">
    <!-- form elements -->
    </div>

References