You are here

function block_inject_get_regions in Block Inject 7

Retrieves from the database the existing declared regions for injection.

3 calls to block_inject_get_regions()
block_inject_get_node_types in ./block_inject.module
Checks if the node type exists already in the "block_inject" table and returns an array of the available node types (not used in any region).
block_inject_get_region_by_node_type in ./block_inject.module
Retrieves from the database the a region for a specific node type.
block_inject_list in ./block_inject.admin.inc
Callback for the main Block Inject page.

File

./block_inject.module, line 358
The Block Inject module functions.

Code

function block_inject_get_regions() {
  $result = db_select('block_inject', 'bi')
    ->fields('bi', array(
    'region',
    'node_type',
    'id',
    'node_name',
    'bi_condition',
  ))
    ->orderBy('region', 'ASC')
    ->execute();
  return $result;
}