You are here

function _biblio_keyword_links in Bibliography Module 6

Same name and namespace in other branches
  1. 5 biblio.module \_biblio_keyword_links()
  2. 6.2 includes/biblio.pages.inc \_biblio_keyword_links()
  3. 7 includes/biblio_theme.inc \_biblio_keyword_links()
  4. 7.2 includes/biblio.theme.inc \_biblio_keyword_links()

Parameters

$keywords:

$base:

Return value

unknown_type

2 calls to _biblio_keyword_links()
theme_biblio_long in ./biblio_theme.inc
DEPRECIATED! this was the original output format which is not to flexable it will be removed TODO: remove this function
theme_biblio_tabular in ./biblio_theme.inc

File

./biblio.pages.inc, line 1095

Code

function _biblio_keyword_links($keywords, $base = 'biblio') {
  $options = array();
  if (isset($_GET['sort'])) {
    $options['query'] .= "sort=" . $_GET['sort'];
  }
  if (isset($_GET['order'])) {
    $options['query'] .= $options['query'] ? "&" : "";
    $options['query'] .= "order=" . $_GET['order'];
  }
  $html = "";
  if (!is_array($keywords)) {
    require_once drupal_get_path('module', 'biblio') . '/biblio.keywords.inc';
    $keywords = biblio_explode_keywords($keywords);
  }
  $sep = check_plain(variable_get('biblio_keyword_sep', ','));
  foreach ($keywords as $kid => $keyword) {
    $html .= empty($html) ? "" : "{$sep} ";
    $html .= l(trim($keyword), "{$base}/keyword/{$kid}", $options);
  }
  return $html;
}