2

the example from the pro drupal book

http://drupal.org

....
$form['annotate']['note'] = array(
'#type' => 'textarea',
'#title' => t('Notes'),
'#default_value' => isset($node->annotation) ? $node->annotation : '',
'#description' => t('Make your personal annotations about this content here.
Only you (and the site administrator) will be able to see them.')
);

$form['annotate']['nid'] = array(
'#type' => 'value',
'#value' => $node->nid,
);
.....

when create the form, he uses the above code. i don't understand this well and don't know what's aim of the code.

$form['annotate']['nid'] = array(
'#type' => 'value',
'#value' => $node->nid,
);

Read »
Created by Dplanet 1 year 24 weeks ago
Category: Modules   Tags:

PSD to Drupal Theme

Drupal Development

Module Development

Get an Estimate

Best published scoops - Modules

Tags for the example from the pro drupal book

Recent comments