title: Dojo, xhrPost does not work with programmatically created form in a dialog
body: <p>I'm creating "programmatically" a form in a dialog, this is shown correctly when the dom is ready.
  Clicking the "Login" button, a POST request is correctly triggered ( I'm checking on chrome debugger ) however, it seems that the POST request does not contain any form data. No usernameF and passwordF parameters in the response.
  The problem does not exists if I try to use xhrPost with a previously (i.e. statically ) instantiated form ( HTML, like all the examples found on the net).
  What's the reason ?</p>
  
  <p>Here's the code:</p>
  
  <pre><code>require([
      "dijit/Dialog",
      "dijit/form/Form",
      "dijit/form/TextBox",
      "dijit/form/Button",
      "dojo/domReady!",
  ], function(Dialog, Form, TextBox, Button)
  {
      var form = new Form({id: "loginformF"});
  
      var usernameF = new TextBox({
          id: "usernameF",
          placeHolder: "Username"
      });
      usernameF.placeAt(form.containerNode);
  
      var passwordF = new TextBox({
          id: "passwordF",
          placeHolder: "Password",
          type: 'password'
      });
      passwordF.placeAt(form.containerNode);
  
      new Button({
          id: "login",
          label: "Login",
          onClick: function(event) {
  
              //chiamata ajax
              dojo.xhrPost({
                  url: "login.php",
                  form: form.containerNode,
                  load: function(data) {
                      console.log("Message posted.");
                  },
                  error: function(error) {
                      console.log("Message posted.");
                  }
              });
              console.log("Message being sent...");
          }
      }).placeAt(form.containerNode);
  
      //crea il dialog
      var dia = new Dialog({
          content: form,
          title: "Dialog with form"
      });
      //form.startup();
      dia.show();
  });
  </code></pre>
  
  <p>Here's the dump of the request/response taken from the Chrome debugger, as you can see there's no "Form Data" section:</p>
  
  <pre><code>Request URL:http://localhost/cv.dojo/login.php
  Request Method:POST
  Status Code:200 OK
  Request Headersview source
  Accept:*/*
  Accept-Encoding:gzip,deflate,sdch
  Accept-Language:it,en-US;q=0.8,en;q=0.6
  Connection:keep-alive
  Content-Length:0
  Content-Type:application/x-www-form-urlencoded
  Host:localhost
  Origin:http://localhost
  Referer:http://localhost/cv.dojo/?
  User-Agent:Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.67 Safari/537.36
  X-Requested-With:XMLHttpRequest
  Response Headersview source
  Connection:Keep-Alive
  Content-Length:10
  Content-Type:text/html
  Date:Mon, 02 Dec 2013 18:31:38 GMT
  Keep-Alive:timeout=5, max=96
  Server:Apache/2.4.4 (Win32) OpenSSL/0.9.8y PHP/5.4.19
  X-Powered-By:PHP/5.4.19
  </code></pre>
  
  <p>I would expect to find a section like this in the response:</p>
  
  <pre><code>Form Dataview sourceview URL encoded
  usernameF:blablablablabla
  passwordF:blablablablabla
  </code></pre>
  
  <p>What's wrong ?</p>