You are here

function _taxonomy_menu_get_mlid in Taxonomy menu 7

Same name and namespace in other branches
  1. 8 taxonomy_menu.database.inc \_taxonomy_menu_get_mlid()
  2. 6.2 taxonomy_menu.database.inc \_taxonomy_menu_get_mlid()
  3. 7.2 taxonomy_menu.database.inc \_taxonomy_menu_get_mlid()

Returns the corresponding menu link id.

Parameters

int $tid: Taxonomy term ID.

int $vid: Vocabulary ID.

Return value

int Menu link ID for that taxonomy term.

4 calls to _taxonomy_menu_get_mlid()
_taxonomy_menu_nodeapi_helper in ./taxonomy_menu.module
Builds argument arrays calls taxonomy_menu_handler.
_taxonomy_menu_save in ./taxonomy_menu.module
Adds/Updates a taxonomy menu item.
_taxonomy_menu_taxonomy_termapi_helper in ./taxonomy_menu.module
Abstraction of hook_taxonomy_term_<operation>()
_taxonomy_menu_update_all_parents in ./taxonomy_menu.module
Updates all parent items.

File

./taxonomy_menu.database.inc, line 36
Database functions

Code

function _taxonomy_menu_get_mlid($tid, $vid) {
  $where = array(
    ':tid' => $tid,
    ':vid' => $vid,
  );
  return db_query('SELECT mlid FROM {taxonomy_menu} WHERE tid = :tid AND vid = :vid', $where)
    ->fetchField();
}