From 59e9b56c6a8e5b26dbe55fc59c40a2e39d9349cc Mon Sep 17 00:00:00 2001 From: Demian Katz <demian.katz@villanova.edu> Date: Tue, 1 Apr 2014 15:54:53 -0400 Subject: [PATCH] Hide citation link when inapplicable. --- .../templates/RecordDriver/SolrDefault/toolbar.phtml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/themes/jquerymobile/templates/RecordDriver/SolrDefault/toolbar.phtml b/themes/jquerymobile/templates/RecordDriver/SolrDefault/toolbar.phtml index 52a9f54322b..f9a1a971b1b 100644 --- a/themes/jquerymobile/templates/RecordDriver/SolrDefault/toolbar.phtml +++ b/themes/jquerymobile/templates/RecordDriver/SolrDefault/toolbar.phtml @@ -5,7 +5,9 @@ <? if ($this->usertags()->getMode() !== 'disabled'): ?> <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'AddTag')?>" data-role="button" rel="external"><?=$this->transEsc("Add Tag")?></a> <? endif; ?> - <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'Cite')?>" data-role="button" rel="external"><?=$this->transEsc("Cite this")?></a> + <? if (count($this->driver->getCitationFormats()) > 0): ?> + <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'Cite')?>" data-role="button" rel="external"><?=$this->transEsc("Cite this")?></a> + <? endif; ?> <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'Email')?>" data-role="button" rel="external"><?=$this->transEsc("Email this")?></a> <a href="<?=$this->recordLink()->getActionUrl($this->driver, 'SMS')?>" data-role="button" rel="external"><?=$this->transEsc("Text this")?></a> </div> -- GitLab