Why is hook_form_alter() not setting default values in _after_build function on /node/add/myct? I've got a validation form (id="mymodule-myct-verify-form") that retrieves data from temp_node to populate it's hidden fields. On submit, the form sends its data to /node/add/myct. (currently via $form['#method' = 'get';, which I'm planning on changing to 'post') What I want to do is this: in mymodule_hook_form_alter, get the data from $_REQUEST (later $_POST) and use that to set the default values of my CCK fields. Currently, jQuery is the approach I'm going for, being unable to get mymodule_form_alter() and mymodule_after_build_convert() to work. Here's what I've got:

 function mymodule_form_alter(&amp;$form, &amp;$form_state, $form_id) {
     if (isset($form['type']) &amp;&amp; isset($form['#node']) &amp;&amp; $form['type']['#value'].'' == "myct") {
        // if converting, set default values through an after_build function
        if (isset($_REQUEST['conv']) &amp;&amp; (strip_tags($_REQUEST['conv']) == 'app') &amp;&amp;
            isset($_REQUEST['taid']) &amp;&amp; (intval($_REQUEST['taid']) &gt; 0)
            &amp;&amp; ($form['type']['#value'] . '_node_form' == $form_id &amp;&amp;
            (strpos($form['#action'], '/node/add/myct') !== FALSE))
        ) { // on the /node/add/myct/?conv=app&amp;taid=1 page, this is true
            $form['#after_build'][] = 'mymodule_after_build_convert';
        }
  }
}

function mymodule_after_build_convert ($form, &amp;$form_state) {
    //TODO: Set default values for CCK fields
    /*dsm($form);
    dsm($form_state);
    dsm($_REQUEST);*/
    // set receiving date and time
    dsm($form['#field_info']['field_status_10']); // date popup
    $form['#field_info']['field_status_10']['widget']['default_value'] = time();     //date("j F, Y - H:i");
    dsm($form['#field_info']['field_status_10']);
    // set deal type (select list)
    $form['#field_info']['field_deal_type']['widget']['default_value'][0]['value'] = intval($_REQUEST['ta_type']);

    return $form;
}


Why is my date_popup field empty instead of containing today's date? Why does the select list not change?
After doing some research, it turns out that taking a JavaScript/jQuery approach is the wrong way to do this. Rather, the code should use hook_form_alter() to retrieve POSTed data ($form['#method'] = 'post';) and set the default values of the node form (including CCK fields) via a function specified with $form['#after_build'].

So, if you want to dig in here and start monkeying with the "real" properties, you need to come in after the point that the CCK form elements are processed. Luckily, the form API has a phase designed for exactly this purpose: #after_build.

/**
 * Implements hook_form_alter().
 */
function example_form_alter(&amp;$form, $form_state, $form_id) {
  // Check for a particular content type's node form.
  if ($form_id == 'example_node_form') {
    // Add an after_build function to process when everything's complete.
    $form['#after_build'][] = 'example_after_build';
  }
}

/**
 * Modifies CCK form elements on the example node form.
 */
function example_after_build($form, &amp;$form_state) {
  // Your code here.
  return $form;
}