You are here

function biblio_combined_bundle_load in Bibliography Module 7.2

Get an individual publication type definition object. Necessary for the %biblio_bundle menu placeholder to work in hook_menu().

Parameters

type $type: The key of the publication type we want

Return value

object The specified publication type.

2 calls to biblio_combined_bundle_load()
biblio_bundle_load in ./biblio.module
contributor_bundle_load in ./biblio.module

File

./biblio.module, line 2765

Code

function biblio_combined_bundle_load($type) {
  foreach (biblio_entities() as $entity) {
    foreach (biblio_types($entity) as $type_name => $info) {
      $types[$type_name] = $info;
    }
  }

  // Replace dashes in a type name with underscores.
  // All Drupal paths use dashes in place of underscores in the URI, but
  // bundle names need to use underscores, not dashes.
  $type = str_replace('-', '_', $type);
  return isset($types[$type]) ? $types[$type] : FALSE;
}