function advpoll_settings_form_validate in Advanced Poll 7.3
Validate admin settings form input.
File
- includes/
advpoll.admin.inc, line 38 - : Advanced Poll administration.
Code
function advpoll_settings_form_validate($form, &$form_state) {
// Ensure precision is an integer.
if (!empty($form_state['values']['advpoll_percentage_precision']) && !is_numeric($form_state['values']['advpoll_percentage_precision'])) {
form_set_error('advpoll_percentage_precision', t('Percentage precision must be an integer.'));
}
}