How can I save form data on a node in Drupal? I want submit form data and save on specific node but I don't know that how to do?

function test1_menu() {
  $items['mytest'] = array(
    'title' =&gt; 'My Tes',
    'page callback' =&gt; 'drupal_get_form',
    'page arguments' =&gt; array('test1_form'),
    'access callback' =&gt; TRUE,
    'weight'=&gt; 1,
    'type'=&gt; MENU_NORMAL_ITEM,
  );
  return items;
}

function test1_form($form, &amp;$form_submit) {
  $form['firstname'] = array(
    '#title' =&gt; t('First Name'),
    '#type' =&gt; 'textfield',
    //'#required' =&gt; TRUE,
  );
  $form['lastname'] = array(
    '#title' =&gt; t('Client Name'),
    '#type' =&gt; 'textfield',
    //'#required' =&gt; TRUE,
  );
  $form['submit'] = array(
    '#value' =&gt; 'Test',
    '#type' =&gt; 'submit',
  );
  return $form;
}

function test1_form_form_submit($form_id, &amp;$form_state) {

}
In your submit function, you just need to create a node, e.g.

$values = array(
  'type' =&gt; $node_type, // Drop in your desired node type.
  'uid' =&gt; $user-&gt;uid, // Want to set an author?
  'status' =&gt; 0,
  'comment' =&gt; 0,
  'promote' =&gt; 0,
);
$entity = entity_create('node', $values);


To make your life easier, I recommend to use entity_metadata_wrapper:

$ewrapper = entity_metadata_wrapper('node', $entity);


Now, you can just cycle through your form data and add the values to the correct fields of your node:

$key = '&lt;MACHINE_NAME OF YOUR FIELD&gt;'; // e.g. "field_firstname"
$val = '&lt;VALUE TO BE SET FOR THAT FIELD&gt;'; // e.g. $form_state['values']['firstname']
$ewrapper-&gt;$key-&gt;set($val);


This of course depends on the field type, the above works for example for simple textfields. Finally, if all is set, just save the freshly created node:

$ewrapper-&gt;save();