|
|
|
@ -76,6 +76,7 @@ function bibcite_footnotes_preprocess_footnote_list(&$variables) {
|
|
|
|
|
$url = Url::fromUserInput('#' . $fn['ref_id'], ['attributes' => ['id' => $fn['fn_id'], 'class' => 'footnote-link']]); |
|
|
|
|
$link = Link::fromTextAndUrl(($footnote_link_text), $url)->toRenderable(); |
|
|
|
|
$build['footnote-link'] = $link; |
|
|
|
|
$override_page_in_citation = $fn['page'] ? $fn['page'] : FALSE; |
|
|
|
|
} |
|
|
|
|
else { |
|
|
|
|
// Output footnote that has more than one reference to it in the body. |
|
|
|
@ -93,6 +94,7 @@ function bibcite_footnotes_preprocess_footnote_list(&$variables) {
|
|
|
|
|
|
|
|
|
|
$i++; |
|
|
|
|
} |
|
|
|
|
$override_page_in_citation = FALSE; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (!empty($fn['text'])) { |
|
|
|
@ -114,7 +116,9 @@ function bibcite_footnotes_preprocess_footnote_list(&$variables) {
|
|
|
|
|
|
|
|
|
|
if (!empty($reference_entity_id)) { |
|
|
|
|
$citation_build = $citation_tools->getRenderableReference($reference_entity_id); |
|
|
|
|
|
|
|
|
|
if ($override_page_in_citation) { |
|
|
|
|
$citation_build['#data']['page'] = $override_page_in_citation; |
|
|
|
|
} |
|
|
|
|
$build[] = $citation_build; |
|
|
|
|
$render = render($build); |
|
|
|
|
$item['#markup'] = $render; |
|
|
|
|