function _advpoll_get_mode in Advanced Poll 5
Same name and namespace in other branches
- 6.3 advpoll.module \_advpoll_get_mode()
- 6 advpoll.module \_advpoll_get_mode()
- 6.2 advpoll.module \_advpoll_get_mode()
7 calls to _advpoll_get_mode()
- advpoll_cancel in ./
advpoll.module - Callback for canceling a vote.
- advpoll_form in ./
advpoll.module - Implementation of hook_form().
- advpoll_form_alter in ./
advpoll.module - Implementation of hook_form_alter().
- advpoll_insert in ./
advpoll.module - Implementation of hook_insert().
- advpoll_view in ./
advpoll.module - Implementation of hook_view().
File
- ./
advpoll.module, line 1209 - Advanced Poll - a sophisticated polling module for voting, elections, and group decision-making.
Code
function _advpoll_get_mode($node_type) {
if ($node_type) {
$mode = explode('advpoll_', $node_type, 2);
return $mode[1];
}
else {
drupal_set_message(t('No mode specified for content type %type.', array(
'%type' => $node_type,
)), 'error');
return '';
}
}