function theme_biblio_export_links in Bibliography Module 7
Same name and namespace in other branches
- 5 biblio.module \theme_biblio_export_links()
- 6.2 includes/biblio_theme.inc \theme_biblio_export_links()
- 6 biblio_theme.inc \theme_biblio_export_links()
- 7.2 includes/biblio.theme.inc \theme_biblio_export_links()
Creates a group of links for the various export functions.
Parameters
$nid: the node id to export (if omitted, all nodes in the current view will be exported
Return value
an un-ordered list of class "biblio-export-buttons"
5 theme calls to theme_biblio_export_links()
- biblio_entry in includes/
biblio.pages.inc - biblio_handler_citation::render in views/
biblio_handler_citation.inc - Render the field.
- biblio_page_header in includes/
biblio.pages.inc - theme_biblio_entry in includes/
biblio_theme.inc - theme_biblio_long in includes/
biblio_theme.inc - Theme function for biblio_long.
File
- includes/
biblio_theme.inc, line 1045
Code
function theme_biblio_export_links($variables) {
global $pager_total_items;
$node = $variables['node'];
$filter = $variables['node'] == NULL && isset($variables['filter']) ? $variables['filter'] : array();
$links = array();
$output = '';
if (biblio_access('export')) {
$show_link = variable_get('biblio_lookup_links', array(
'google' => TRUE,
));
$lookup_links = module_invoke_all('biblio_lookup_link', $node);
if ($show_link['google'] && !empty($node)) {
$lookup_links['biblio_google_scholar'] = theme('google_scholar_link', array(
'node' => $node,
));
}
$nid = isset($node->nid) ? $node->nid : NULL;
$export_links = module_invoke_all('biblio_export_link', $nid, $filter);
$links = array_merge($lookup_links, $export_links);
}
if (empty($node) && !empty($links)) {
$output = t('Export @count results', array(
'@count' => $pager_total_items[0],
)) . ': ';
}
return $output . theme('links', array(
'links' => $links,
'attributes' => array(
'class' => array(
'biblio-export-buttons',
),
),
));
}