You are here

function book_link_load in Drupal 6

Same name and namespace in other branches
  1. 7 modules/book/book.module \book_link_load()

Like menu_link_load(), but adds additional data from the {book} table.

Do not call when loading a node, since this function may call node_load().

2 calls to book_link_load()
book_nodeapi in modules/book/book.module
Implementation of hook_nodeapi().
template_preprocess_book_navigation in modules/book/book.module
Process variables for book-navigation.tpl.php.

File

modules/book/book.module, line 1024
Allows users to structure the pages of a site in a hierarchy or outline.

Code

function book_link_load($mlid) {
  if ($item = db_fetch_array(db_query("SELECT * FROM {menu_links} ml INNER JOIN {book} b ON b.mlid = ml.mlid LEFT JOIN {menu_router} m ON m.path = ml.router_path WHERE ml.mlid = %d", $mlid))) {
    _menu_link_translate($item);
    return $item;
  }
  return FALSE;
}