You are here

function sheetnode_widget in Sheetnode 5

Same name and namespace in other branches
  1. 6 sheetnode.module \sheetnode_widget()

Implementation of hook_widget().

File

./sheetnode.module, line 527

Code

function sheetnode_widget(&$form, &$form_state, $field, $items, $delta = 0) {
  $element = array(
    '#type' => $field['widget']['type'],
    '#default_value' => isset($items[$delta]) ? $items[$delta] : '',
  );
  return $element;
}