You are here

function iframe_widget in Iframe 6

Implementation of hook_widget().

File

./iframe.module, line 265
Defines simple iframe field types. based on the cck-module "link" by quicksketch MODULE-Funtions

Code

function iframe_widget(&$form, &$form_state, $field, $items, $delta = 0) {
  dmsg(3, 'func iframe_widget');
  $element = array(
    '#type' => $field['widget']['type'],
    '#default_value' => isset($items[$delta]) ? $items[$delta] : '',
    '#title' => $field['widget']['label'],
    '#weight' => $field['widget']['weight'],
    '#description' => $field['widget']['description'],
    '#required' => $field['required'],
    '#field' => $field,
  );
  return $element;
}