You are here

function library_display_items in Library 7

Same name and namespace in other branches
  1. 5.2 library.pages.inc \library_display_items()
  2. 6.2 library.pages.inc \library_display_items()
  3. 6 library.pages.inc \library_display_items()

Display all library items.

Return value

string Themed results.

1 string reference to 'library_display_items'
library_menu in ./library.module
Implements hook_menu().

File

./library.pages.inc, line 565
Functions for generating page displays related to the library module.

Code

function library_display_items() {
  $var = library_get_table_header();
  $header = $var['header'];
  $nodes = library_get_items_group_by_node();
  $rows = array();
  foreach ($nodes as $node) {
    $rows[] = library_get_table_row($node, $var);
  }
  $output = theme('table', array(
    'header' => $header,
    'rows' => $rows,
    'attributes' => array(
      'data' => array(
        'class' => 'library-list',
      ),
    ),
  ));
  $output .= theme('pager');
  return $output;
}