function weather_search_form in Weather 7
Same name and namespace in other branches
- 6.5 weather.module \weather_search_form()
- 7.3 weather.forms.inc \weather_search_form()
- 7.2 weather.forms.inc \weather_search_form()
Display a form for the user to search for weather locations.
1 string reference to 'weather_search_form'
- weather_search_location in ./
weather.forms.inc - Search for a given location.
File
- ./
weather.forms.inc, line 714 - Provide forms for configuration of weather displays.
Code
function weather_search_form($form, &$form_state) {
$form['search'] = array(
'#type' => 'textfield',
'#title' => t('Search for a location'),
'#description' => t('Type in an ICAO code, a name, or a country to search for weather conditions at that location.'),
'#autocomplete_path' => 'weather/autocomplete',
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Search'),
);
return $form;
}