You are here

function _gateways_build in SMS Framework 6

Same name and namespace in other branches
  1. 5 sms.module \_gateways_build()
  2. 6.2 sms.module \_gateways_build()
  3. 7 sms.module \_gateways_build()
1 call to _gateways_build()
sms_gateways in ./sms.module
Get a list of all gateways

File

./sms.module, line 257
The core of the SMS Framework. Provides gateway managment and API for sending and receiving SMS messages.

Code

function _gateways_build() {
  $_gateways = array();
  $_names = array();
  $gateway_array = module_invoke_all('gateway_info');
  foreach ($gateway_array as $identifier => $info) {
    $info['configuration'] = variable_get('sms_' . $identifier . '_settings', '');
    $_gateways[$identifier] = $info;
    $_names[$identifier] = $info['name'];
  }
  asort($_names);
  return array(
    $_gateways,
    $_names,
  );
}