function tweet_feed_field_widget_form in Tweet Feed 7.2
Same name and namespace in other branches
- 7.3 tweet_feed.field_info.inc \tweet_feed_field_widget_form()
Implements hook_field_widget_form().
File
- ./
tweet_feed.field_info.inc, line 110
Code
function tweet_feed_field_widget_form(&$form, &$form_state, $field, $instance, $langcode, $items, $delta, $element) {
if ($field['type'] == 'tweet_feed_user_mention') {
$element['tweet_feed_mention_name'] = array(
'#type' => 'textfield',
'#title' => t('Name'),
'#default_value' => isset($items[$delta]['tweet_feed_mention_name']) ? $items[$delta]['tweet_feed_mention_name'] : '',
'#size' => 60,
'#maxlength' => 255,
);
$element['tweet_feed_mention_screen_name'] = array(
'#type' => 'textfield',
'#title' => t('Screen Name'),
'#default_value' => isset($items[$delta]['tweet_feed_mention_screen_name']) ? $items[$delta]['tweet_feed_mention_screen_name'] : '',
'#size' => 60,
'#maxlength' => 255,
);
$element['tweet_feed_mention_id'] = array(
'#type' => 'textfield',
'#title' => t('ID'),
'#default_value' => isset($items[$delta]['tweet_feed_mention_id']) ? $items[$delta]['tweet_feed_mention_id'] : '',
'#size' => 60,
'#maxlength' => 255,
);
}
return $element;
}