function pay_handlers in Pay 7
Same name and namespace in other branches
- 6 pay.module \pay_handlers()
API Function: All available payment handlers.
14 calls to pay_handlers()
- pay::handler_title in includes/
handlers/ pay.inc - pay::permissions_settings in includes/
handlers/ pay.inc - pay_admin_method_form in includes/
pay.admin.inc - Admin form to create or update payment methods.
- pay_admin_method_overview in includes/
pay.admin.inc - pay_admin_pay_form_list in includes/
pay.admin.inc - List payment forms
File
- ./
pay.module, line 182 - Pay module allows for accepting payments using pluggable payment backends.
Code
function pay_handlers($type, $handler_name = NULL, $refresh = FALSE) {
static $handlers = array();
if ($refresh || !isset($handlers[$type])) {
module_load_include('inc', 'pay', 'includes/pay.handlers');
$handlers[$type] = module_invoke_all($type . '_handler_info');
foreach ($handlers[$type] as $name => $info) {
if (!isset($info['module'])) {
$handlers[$type][$name]['module'] = $name;
}
if (!isset($info['handler'])) {
$handlers[$type][$name]['handler'] = $name;
}
}
}
if ($handler_name) {
return $handlers[$type][$handler_name];
}
return $handlers[$type];
}