function _biblio_single_author_link in Bibliography Module 5
1 call to _biblio_single_author_link()
- theme_biblio_format_authors in ./biblio.module
File
- ./biblio.module, line 3083
Code
function _biblio_single_author_link($author, $base = 'biblio', $inline = false) {
$query = null;
$inline = $inline ? "/inline" : "";
$attrib = null;
if (isset($_GET['sort'])) {
$query .= "sort=" . $_GET['sort'];
}
if (isset($_GET['order'])) {
$query .= $query ? "&" : "";
$query .= "order=" . $_GET['order'];
}
$html = "";
$html .= empty($html) ? "" : "; ";
if (strstr($author, ",")) {
$parts = split(",", $author);
$lastname = $parts[0];
}
else {
$parts = split(" ", $author);
$lastname = end($parts);
}
$html .= l(trim($author), "{$base}/author/" . trim($lastname) . $inline, $attrib, $query);
return $html;
}