Kauri Documentation
 PreviousHomeNext 
10.2 Standard UsageBook Index10.3 Hacker-Guide

10.2.2 Creating the form

10.2.2.1 Creating the Kauri form by giving the id to the Form constructor

When configured the form, all that rests is to create the form by calling the Form constructor with 2 arguments:

  1. the id of the form in html
  2. the fconf (form configuration) we created above
     jQuery(document).ready(function() {
          var basicForm = new jQuery.org.kauriproject.forms.Form("basic-form", fconf);
      });

And the html for this form looks as simple as this:

    <form id="basic-form" method="get" action="" >
    </form>

10.2.2.2 Creating the Kauri form with jQuery

Another possibility is to create the form in jQuery and passing this jQuery wrapper to function kauriform:

var basicForm = $("<form/>").appendTo($("div#someId")).kauriform(fconf);
 PreviousHomeNext 
10.2 Standard Usage10.3 Hacker-Guide