search_box
- Versions
- 4.7
search_box($form_id = 'search_theme_form')- 5
search_box($form_id)- 6
search_box(&$form_state, $form_id)- 7
search_box($form, &$form_state, $form_id)
Form builder; Output a search form for the search block's search box.
See also
@see search-theme-form.tpl.php
See also
Related topics
Code
modules/search/search.module, line 896
<?php
function search_box($form, &$form_state, $form_id) {
$form[$form_id] = array(
'#type' => 'textfield',
'#size' => 15,
'#default_value' => '',
'#attributes' => array('title' => t('Enter the terms you wish to search for.')),
);
$form['submit'] = array('#type' => 'submit', '#value' => t('Search'));
$form['#submit'][] = 'search_box_form_submit';
return $form;
}
?>Login or register to post comments 