diff --git a/local/config/vufind/config.ini b/local/config/vufind/config.ini index c4f84f2d911ca450e130da97c843e02fba6688f0..a7c4da375e38acf6bfa3d1957aaddb39f36e5164 100644 --- a/local/config/vufind/config.ini +++ b/local/config/vufind/config.ini @@ -26,6 +26,8 @@ autoConfigure = true url = http://localhost/vufind_generic email = dummy@vufind.org title = "Generic Katalog (devel)" +; The separator used between page name and site name in the <title> tag of pages. +titleSeparator = "::" ; This is the default theme for non-mobile devices (or all devices if mobile_theme ; is disabled below). Available standard themes: ; bootstrap3 = HTML5 theme using Bootstrap 3 + jQuery libraries, with minimal diff --git a/local/languages/de.ini b/local/languages/de.ini index 144a30c70ca1deeb25f86906093ba7b143947f42..fc2852d71200a869d5c844346094cca46eb94636 100644 --- a/local/languages/de.ini +++ b/local/languages/de.ini @@ -2077,3 +2077,6 @@ missing_record_exception = "Der aufgerufene Titel (%%id%%) ist nicht vorhanden." ; #18611 unknown resolver state 10 Unknown Electronic = "Titel ist beim Resolver-Service nicht bekannt" + +; #20826 +title_wrapper = "%%pageTitle%% %%titleSeparator%% %%siteTitle%%" \ No newline at end of file diff --git a/local/languages/en.ini b/local/languages/en.ini index 807e7d4350ab48baab9f48c06ec2fa6891b7f24f..48a6d2dbab0cae35c423264ffc0f5f85d83fe4fb 100644 --- a/local/languages/en.ini +++ b/local/languages/en.ini @@ -2165,3 +2165,6 @@ missing_record_exception = "Record %%id%% is unavailable." ; #18611 unknown resolver state 10 Unknown Electronic = "Record is unknown to the resolver service" + +; #20826 +title_wrapper = "%%pageTitle%% %%titleSeparator%% %%siteTitle%%" \ No newline at end of file diff --git a/module/finc/src/finc/ILS/Driver/FincILS.php b/module/finc/src/finc/ILS/Driver/FincILS.php index 4dbb8c94e4b9546cae0e9e32304a6b741760f398..6a204440bdc41f2122b145e283d04b7763521c23 100644 --- a/module/finc/src/finc/ILS/Driver/FincILS.php +++ b/module/finc/src/finc/ILS/Driver/FincILS.php @@ -421,7 +421,7 @@ class FincILS extends PAIA implements LoggerAwareInterface $retval = array_fill(0, count($ids), false); foreach ($new['first_results'] as $record) { /** @var \finc\RecordDriver\SolrDefault $record */ - $callNumbers = $record->getField($idType); + $callNumbers = (array)$record->getField($idType); $matches = array_intersect($ids, $callNumbers); foreach ($matches as $number => $match) { /* map identifier to solr id */ diff --git a/module/finc/src/finc/ILS/Driver/FincLibero.php b/module/finc/src/finc/ILS/Driver/FincLibero.php index 683a3f94a850ec6fcf39170c83aac0e0330260a4..116bcf3881f4989ecc7f945dc03a3c83dad32a86 100644 --- a/module/finc/src/finc/ILS/Driver/FincLibero.php +++ b/module/finc/src/finc/ILS/Driver/FincLibero.php @@ -454,6 +454,20 @@ class FincLibero extends FincILS implements TranslatorAwareInterface return $details; } + /** + * Returns the value for "callnumber" in VuFind getStatus/getHolding array + * + * @param array $item Array with DAIA item data + * + * @return string + */ + protected function getItemCallnumber($item) + { + return isset($item['label']) && !empty($item['label']) + ? $item['label'] + : ''; + } + /** * FincLibero specific overrides of DAIA methods */ diff --git a/module/finc/src/finc/ILS/Driver/LiberoWachtlTrait.php b/module/finc/src/finc/ILS/Driver/LiberoWachtlTrait.php index 6135ea641d59fa38bd564fea19572276f6edb3af..343989de53894480b66d025a5190961018c2bf74 100644 --- a/module/finc/src/finc/ILS/Driver/LiberoWachtlTrait.php +++ b/module/finc/src/finc/ILS/Driver/LiberoWachtlTrait.php @@ -344,67 +344,6 @@ trait LiberoWachtlTrait return $bool; } - /** - * Change values of users profile. - * - * @param array $inval Associative array of key => value. Keys are: - * - memberCode : User ID returned by patronLogin - * - street : street and number - * - additional : optional address value - * - city : city/village - * - zipCode : location zip code - * - emailAddress : email address - * - reason : reason of change - * @param array $patron Patron data - * - * @return boolean true OK, false FAIL - * @access public - * @throws \Exception Throws ILSException - */ - public function setMyProfile($inval, $patron) - { - $map = self::profileDataMapper(true); - - $params = $this->getLiberoWachtlRequestParams(); - $params['memberCode'] = $patron['cat_username']; - $params['password'] = $patron['cat_password']; - - $data = []; - if (is_array($inval) && (count($inval) > 0)) { - foreach ($inval as $k => $v) { - if (isset($map[$k])) { - $data[$map[$k]] = $v; - } else { - $data[$k] = $v; - } - } - } - - $params = array_merge($params, $data); - - try { - $result = $this->httpService->get( - $this->getLiberoWachtlUrl() .'setMyProfile.jsp', - $params, - null, - $this->getLiberoWachtlRequestHeaders() - ); - } catch (\Exception $e) { - throw new ILSException($e->getMessage()); - } - - if (!$result->isSuccess()) { - // log error for debugging - $this->debug( - 'HTTP status ' . $result->getStatusCode() . - ' received' - ); - return false; - } - - return $this->getLiberoWachtlResultBool($result); - } - /** * Returns Array with profile fields that are never allowed to be edited * diff --git a/module/finc/src/finc/View/Helper/Root/Factory.php b/module/finc/src/finc/View/Helper/Root/Factory.php index 4e44d5bae6a6e2bf0f8fa2a1aac7ae8a438cfb84..82c343ba186660ec99e903001f73c65ed609594d 100644 --- a/module/finc/src/finc/View/Helper/Root/Factory.php +++ b/module/finc/src/finc/View/Helper/Root/Factory.php @@ -211,19 +211,6 @@ class Factory ); } - /** - * Construct Head Title Helper - * - * @param ContainerInterface $container Service manager - * - * @return HeadTitle - */ - public static function getHeadTitle(ContainerInterface $container) - { - $config = $container->get('VuFind\Config')->get('config')->Site; - return new HeadTitle($config->title ?? ''); - } - /** * Construct ExternalLink * diff --git a/module/finc/src/finc/View/Helper/Root/HeadTitle.php b/module/finc/src/finc/View/Helper/Root/HeadTitle.php deleted file mode 100644 index c4036a17429c5da292fb5e574bf9f40d53de3588..0000000000000000000000000000000000000000 --- a/module/finc/src/finc/View/Helper/Root/HeadTitle.php +++ /dev/null @@ -1,58 +0,0 @@ -<?php -/** - * Head Title view helper - * - * PHP version 7 - * - * Copyright (C) Leipzig University Library 2020. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2, - * as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * @category VuFind - * @package View_Helpers - * @author Dorian Merz <merz@ub.uni-leipzig.de> - * @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License - * @link https://vufind.org/wiki/development Wiki - */ -namespace finc\View\Helper\Root; - -use Zend\View\Helper\HeadTitle as BaseHelper; - -/** - * Head Title view helper - * - * @category VuFind - * @package View_Helpers - * @author Dorian Merz <merz@ub.uni-leipzig.de> - * @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License - * @link https://vufind.org/wiki/development Wiki - */ -class HeadTitle extends BaseHelper -{ - protected $headerSuffix; - - public function __construct($headerSuffix = '') - { - parent::__construct(); - if (!empty($headerSuffix)) { - $this->headerSuffix = ' - '.$headerSuffix; - } - } - - public function __invoke($title = null, $setType = null) - { - $title = $title ? : $this->headerSuffix; - return parent::__invoke($title, $setType); - } -} diff --git a/themes/finc/templates/Auth/AbstractBase/resetpassword.phtml b/themes/finc/templates/Auth/AbstractBase/resetpassword.phtml index 379fd2fbdd2e9e13bd500a6dce199b62698a619d..ed63456d5f7021511cfd29ab0f268c7175593362 100644 --- a/themes/finc/templates/Auth/AbstractBase/resetpassword.phtml +++ b/themes/finc/templates/Auth/AbstractBase/resetpassword.phtml @@ -2,7 +2,7 @@ <?php /* compare with BS login templates in Auth during updates */ ?> <?php // Set page title. -$this->headTitle($this->translate('Reset Password') . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Reset Password')); ?> <h1><?=$this->transEsc('Reset Password')?></h1> <form method="post" name="resetPasswordForm" action="<?=$this->url('myresearch-resetpassword')?>"> diff --git a/themes/finc/templates/RecordTab/acquisitionpda.phtml b/themes/finc/templates/RecordTab/acquisitionpda.phtml index ed7a386cde1c1ae3812954f441cc60ef35cb81b2..91296ba15fa006a007013d4545a6cbfcb675aa6f 100644 --- a/themes/finc/templates/RecordTab/acquisitionpda.phtml +++ b/themes/finc/templates/RecordTab/acquisitionpda.phtml @@ -4,7 +4,6 @@ $this->headTitle( $this->translate('PDA::Acquisition') . ': ' . $this->driver->getBreadcrumb() - . ' | ' . $this->translate("LibraryName") ); // Get some variables $id = $this->driver->getUniqueId(); diff --git a/themes/finc/templates/RecordTab/description.phtml b/themes/finc/templates/RecordTab/description.phtml index 9978227ede0bfccc83dc8c95544d3e674b78b736..0e39ff89ba9bad658a112800f42272aa2d5adde1 100644 --- a/themes/finc/templates/RecordTab/description.phtml +++ b/themes/finc/templates/RecordTab/description.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - description --> <?php // Set page title. -$this->headTitle($this->translate('Description') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Description') . ': ' . $this->driver->getBreadcrumb()); $formatter = $this->recordDataFormatter(); $mainFields = $formatter->getData($driver, $formatter->getDefaults('description')); diff --git a/themes/finc/templates/RecordTab/descriptionlido.phtml b/themes/finc/templates/RecordTab/descriptionlido.phtml index 221d9845697b85d4f1958a4f7e8acaca99247eff..939b171f95eefcc3f9f00317a898dafd25cf85b9 100644 --- a/themes/finc/templates/RecordTab/descriptionlido.phtml +++ b/themes/finc/templates/RecordTab/descriptionlido.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - descriptionlido --> <?php // Set page title. -$this->headTitle($this->translate('Description') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Description') . ': ' . $this->driver->getBreadcrumb()); $formatter = $this->recordDataFormatter(); $mainFields = $formatter->getData($driver, $formatter->getDefaults('description-lido')); diff --git a/themes/finc/templates/RecordTab/hierarchytree.phtml b/themes/finc/templates/RecordTab/hierarchytree.phtml index dfc402d78303083e7f2f1c81097c7fee6c9dec90..0c5f7f1879a63203bbb26f691421c32928f8dad5 100644 --- a/themes/finc/templates/RecordTab/hierarchytree.phtml +++ b/themes/finc/templates/RecordTab/hierarchytree.phtml @@ -1,7 +1,7 @@ <!-- finc: record-tab - hierarchytree --> <?php // Set page title. - $this->headTitle($this->translate('hierarchy_tree') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('hierarchy_tree') . ': ' . $this->driver->getBreadcrumb()); $hierarchyTreeList = $this->tab->getTreeList(); $activeTree = $this->tab->getActiveTree(); diff --git a/themes/finc/templates/RecordTab/holdingsils.phtml b/themes/finc/templates/RecordTab/holdingsils.phtml index b78c5f34b091958a8cc8ef0a7b03cfe56abd3173..d929e6b59b9855a214f6df8fa0c0852f307a6d1e 100644 --- a/themes/finc/templates/RecordTab/holdingsils.phtml +++ b/themes/finc/templates/RecordTab/holdingsils.phtml @@ -26,7 +26,7 @@ } } // Set page title. - $this->headTitle($this->translate('Holdings') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Holdings') . ': ' . $this->driver->getBreadcrumb()); ?> <?php /* finc-specific: nxt line - #7841@56988450 - CK */ ?> diff --git a/themes/finc/templates/RecordTab/serviceebl.phtml b/themes/finc/templates/RecordTab/serviceebl.phtml index 5ef8e11a1e920bb79aafc7a5a75c536fecd8bd66..edb3e1171bcbc3daeae2214b6fe827fb5b0105e2 100644 --- a/themes/finc/templates/RecordTab/serviceebl.phtml +++ b/themes/finc/templates/RecordTab/serviceebl.phtml @@ -1,6 +1,6 @@ <?php // Set page title. -$this->headTitle($this->translate('EBL') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('EBL') . ': ' . $this->driver->getBreadcrumb()); // Get EBL url $link = $this->tab->getLinkEBL(); diff --git a/themes/finc/templates/RecordTab/staffviewai.phtml b/themes/finc/templates/RecordTab/staffviewai.phtml index 62a5748a6bf89b2aa11b6070c638923dd7f5ed85..d38b62fdc2e8e2c10139f41c3ef7feafe24b00ea 100644 --- a/themes/finc/templates/RecordTab/staffviewai.phtml +++ b/themes/finc/templates/RecordTab/staffviewai.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - staffviewai --> <?php // Set page title. -$this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb()); ?> <?php /* include responsive data table - CK */ ?> <table class="citation table table-striped table-resp-data"> diff --git a/themes/finc/templates/RecordTab/staffviewarray.phtml b/themes/finc/templates/RecordTab/staffviewarray.phtml index 73fac7db40f4c14da918d763e6626f7e32bef0b8..c046901cfae8ac587a7212b2c298778d27e6bf99 100644 --- a/themes/finc/templates/RecordTab/staffviewarray.phtml +++ b/themes/finc/templates/RecordTab/staffviewarray.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - staffviewarray --> <?php // Set page title. - $this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb()); ?> <?php /* include responsive data table - CK */ ?> <table class="citation table table-striped table-resp-data"> diff --git a/themes/finc/templates/RecordTab/staffviewmarc.phtml b/themes/finc/templates/RecordTab/staffviewmarc.phtml index 19f2aa691b4c7e449cbb5031ff7b35fa277773a6..ebd800bbd7d5e6d2d6ed8fbd27770e893a99748a 100644 --- a/themes/finc/templates/RecordTab/staffviewmarc.phtml +++ b/themes/finc/templates/RecordTab/staffviewmarc.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - staffviewmarc --> <?php // Set page title. -$this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Staff View') . ': ' . $this->driver->getBreadcrumb()); ?> <?=\VuFind\XSLT\Processor::process('record-marc.xsl', $this->driver->getXML('marc21'))?> <?php /* the following introduced in 9934*/ ?> diff --git a/themes/finc/templates/RecordTab/topics.phtml b/themes/finc/templates/RecordTab/topics.phtml index eac80af00c6e507c3d5e595f6dea59ab42a37f47..40d1f149f839a6b4f7ab6fa43499d9ce7711dd26 100644 --- a/themes/finc/templates/RecordTab/topics.phtml +++ b/themes/finc/templates/RecordTab/topics.phtml @@ -1,7 +1,7 @@ <!-- finc: recordtab - topics --> <?php // Set page title. -$this->headTitle($this->translate('Topics') . ': ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Topics') . ': ' . $this->driver->getBreadcrumb()); ?> <table class="table table-striped table-resp-data"> diff --git a/themes/finc/templates/admin/home.phtml b/themes/finc/templates/admin/home.phtml index 57ba0f0328634cd6ce63370cb6a12c8c0308ebda..5e8aa62a4df836ff1d9e1273b9cc352803b0394d 100644 --- a/themes/finc/templates/admin/home.phtml +++ b/themes/finc/templates/admin/home.phtml @@ -5,7 +5,7 @@ */ // Set page title. - $this->headTitle($this->translate('VuFind Administration - Home') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('VuFind Administration - Home')); // Set up map of core name => label $coreLabels = [ diff --git a/themes/finc/templates/alphabrowse/home.phtml b/themes/finc/templates/alphabrowse/home.phtml index ccd0a1caca6663b2abf1e2b3c28650f5361659b3..0e024ed7736b62ce650b2ecb94301eaa95c34525 100644 --- a/themes/finc/templates/alphabrowse/home.phtml +++ b/themes/finc/templates/alphabrowse/home.phtml @@ -1,6 +1,6 @@ <!-- finc - templates - alphabrowse - home --> <?php - $this->headTitle($this->translate('Browse the Collection Alphabetically') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Browse the Collection Alphabetically')); $this->layout()->breadcrumbs = '<a href="' . $this->url('alphabrowse-home') . '">' . $this->transEsc('Browse Alphabetically') . '</a>'; $baseQuery = ['source' => $this->source, 'from' => $this->from]; diff --git a/themes/finc/templates/amsl/sources-list.phtml b/themes/finc/templates/amsl/sources-list.phtml index 5946ef486e2eb1b9155d158144cf9845ed0c7bb8..371f906684de2b40f1af54bc0857935c9662358e 100644 --- a/themes/finc/templates/amsl/sources-list.phtml +++ b/themes/finc/templates/amsl/sources-list.phtml @@ -8,7 +8,7 @@ <!-- finc: amsl/sources-list - home --> <?php // Set up page title: -$this->headTitle($this->translate('List of available Sources') . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('List of available Sources')); // Set up breadcrumbs: $this->layout()->breadcrumbs .= '</li> <li class="active">' . $this->transEsc('List of available Sources') . '</li>'; diff --git a/themes/finc/templates/browse/home.phtml b/themes/finc/templates/browse/home.phtml index bac20ae20af94ca87b00416f6e717201e4807567..d20402286c31d1e1cb1a62bc133202e76d32be3a 100644 --- a/themes/finc/templates/browse/home.phtml +++ b/themes/finc/templates/browse/home.phtml @@ -2,7 +2,7 @@ <?php /* copied from bootstrap3 - added h1 for sr-only - #17596 - HR */?> <?php - $this->headTitle($this->translate('Browse the Catalog') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Browse the Catalog')); $this->layout()->breadcrumbs = '<a href="' . $this->url('browse-home') . '">' . $this->transEsc('Browse') . '</a>'; $BROWSE_BASE = $this->url('browse-' . strtolower($this->currentAction)); diff --git a/themes/finc/templates/cart/cart.phtml b/themes/finc/templates/cart/cart.phtml index 53de8590ca3166083e4306543a0e650e8f76747d..7ac208d9e771e3d811ae9d85a734363d7bf9ab7f 100644 --- a/themes/finc/templates/cart/cart.phtml +++ b/themes/finc/templates/cart/cart.phtml @@ -1,7 +1,7 @@ <!-- finc: cart - cart --> <?php // Set page title. - $this->headTitle($this->translate('Book Bag') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Book Bag')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li>' . $this->searchMemory()->getLastSearchLink($this->transEsc('Search'), '', '</li> ') diff --git a/themes/finc/templates/cart/email.phtml b/themes/finc/templates/cart/email.phtml index e4498df745d3b85842e6f3c979f61e920a4985c1..54d82cec86f881f049b263075dbd504ce3b1bec2 100644 --- a/themes/finc/templates/cart/email.phtml +++ b/themes/finc/templates/cart/email.phtml @@ -3,7 +3,7 @@ <?php // Set page title. - $this->headTitle($this->translate('email_selected_favorites') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('email_selected_favorites')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li>' . $this->searchMemory()->getLastSearchLink($this->transEsc('Search'), '', '</li> ') diff --git a/themes/finc/templates/cart/save.phtml b/themes/finc/templates/cart/save.phtml index dd40f5249f412408ae436a86365ffb3833155def..92183fe7ae68d337ba0517f85ad01e5049ff4638 100644 --- a/themes/finc/templates/cart/save.phtml +++ b/themes/finc/templates/cart/save.phtml @@ -3,7 +3,7 @@ <?php // Set page title. - $this->headTitle($this->translate('bookbag_save_selected') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('bookbag_save_selected')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li>' . $this->searchMemory()->getLastSearchLink($this->transEsc('Search'), '', '</li> ') . diff --git a/themes/finc/templates/channels/home.phtml b/themes/finc/templates/channels/home.phtml index 5220503f93636b5e0b7bb097ad31ca3fe70d1923..5bf072cc53b5b52ba409d30d005d485f67a0ac57 100644 --- a/themes/finc/templates/channels/home.phtml +++ b/themes/finc/templates/channels/home.phtml @@ -3,7 +3,7 @@ <?php // Set up page title: - $this->headTitle($this->translate('Channels') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Channels')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li class="active">' . $this->transEsc('Channels') . '</li>'; diff --git a/themes/finc/templates/documentdeliveryservice/home.phtml b/themes/finc/templates/documentdeliveryservice/home.phtml index d92c526dd57cddd74c48d8f4bb696bbdbf4b6f47..db283942371cf432ffc274e3b675f55af9d3ed8c 100644 --- a/themes/finc/templates/documentdeliveryservice/home.phtml +++ b/themes/finc/templates/documentdeliveryservice/home.phtml @@ -1,6 +1,6 @@ <?php // Set up page title: -$this->headTitle($this->translate('Delivery service for documents') . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Delivery service for documents')); ?> <?=($this->loadForm ? $this->render('documentdeliveryservice/zform.phtml') : $this->flashmessages());?> \ No newline at end of file diff --git a/themes/finc/templates/header.phtml b/themes/finc/templates/header.phtml index b41ef9b5fc916344ffe13ce9d0cda562b4c95630..50d239b701eb65722cd1115f6bdc0c405fae1650 100644 --- a/themes/finc/templates/header.phtml +++ b/themes/finc/templates/header.phtml @@ -38,7 +38,7 @@ if ($cart->isActive()): ?> <li id="cartSummary"> <a id="cartItems" class="btn" data-lightbox title="<?=$this->transEsc('View Book Bag')?>" href="<?=$this->url('cart-home')?>"> - <i class="fa fa-clipboard" aria-hidden="true"></i> <span class="sr-only"><?=$this->transEsc('Book Bag')?>:</span> <strong><?=count($cart->getItems())?></strong> <span class="cart-label"><?=$this->transEsc('items')?></span> + <i class="fa fa-clipboard" aria-hidden="true"></i> <span role="status"><span class="sr-only"><?=$this->transEsc('Book Bag')?>:</span> <strong><?=count($cart->getItems())?></strong> <span class="cart-label"><?=$this->transEsc('items')?></span></span> <span class="sr-only full<?=!$cart->isFull() ? ' hidden' : ''?>">(<?=$this->transEsc('bookbag_full')?>)</span> </a> </li> diff --git a/themes/finc/templates/layout/layout.phtml b/themes/finc/templates/layout/layout.phtml index 898b0e194a6543dee78370def3c9e928c51b3e5e..a269a91e3a942567214f3c2f97c6b620544988bb 100644 --- a/themes/finc/templates/layout/layout.phtml +++ b/themes/finc/templates/layout/layout.phtml @@ -8,8 +8,20 @@ <meta http-equiv="X-UA-Compatible" content="IE=edge"/> <meta name="viewport" content="width=device-width,initial-scale=1.0"/> <?=$this->headMeta()?> - <?=$this->headTitle()?> <?php + // Pullrequest 2157 Ticket #20826 + // Format the page title using the translation system: + $siteConfig = $this->config()->get('config')->Site; + $fullTitle = $this->translate( + 'title_wrapper', + [ + '%%pageTitle%%' => $this->headTitle()->renderTitle(), + '%%siteTitle%%' => $siteConfig->title, + '%%titleSeparator%%' => $siteConfig->titleSeparator ?? '::' + ] + ); + echo $this->headTitle($fullTitle, \Zend\View\Helper\Placeholder\Container\AbstractContainer::SET); + // Set up OpenSearch link: $this->headLink( [ diff --git a/themes/finc/templates/librarycards/editcard.phtml b/themes/finc/templates/librarycards/editcard.phtml index 34c7edc473a76f2e50c49eca4f540d84d4fc42e0..9a7926db76b7240eaabdc86e678bccbaf0ab8cb3 100644 --- a/themes/finc/templates/librarycards/editcard.phtml +++ b/themes/finc/templates/librarycards/editcard.phtml @@ -2,7 +2,7 @@ <?php // Set up page title: $pageTitle = empty($this->card->id) ? 'Add a Library Card' : "Edit Library Card"; - $this->headTitle($this->translate($pageTitle) . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate($pageTitle)); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li>' diff --git a/themes/finc/templates/librarycards/home.phtml b/themes/finc/templates/librarycards/home.phtml index 5ded3c3ad5ab34855ee8dc96658d5d455be730cd..25338aa28e5edea51bc2a71d4f43f48a6918bd21 100644 --- a/themes/finc/templates/librarycards/home.phtml +++ b/themes/finc/templates/librarycards/home.phtml @@ -1,7 +1,7 @@ <!-- finc: librarycards - home --> <?php // Set up page title: - $this->headTitle($this->translate('Library Cards') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Library Cards')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Library Cards') . '</li>'; diff --git a/themes/finc/templates/myresearch/account.phtml b/themes/finc/templates/myresearch/account.phtml index 93352dd3908d86ca3485ed1c6c20d99ea20bcb2b..b1055a8c55baea6e4f76428bbad1ef93d11cedae 100644 --- a/themes/finc/templates/myresearch/account.phtml +++ b/themes/finc/templates/myresearch/account.phtml @@ -2,7 +2,7 @@ <?php // Set up page title: - $this->headTitle($this->translate('User Account') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('User Account')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Account') . '</li>'; diff --git a/themes/finc/templates/myresearch/acquisition.phtml b/themes/finc/templates/myresearch/acquisition.phtml index 0d2140246d9337b1bc9ef9ea63855496878d6bfd..62d81badc6f0194afb2e0de9effce3391e3e3ab6 100644 --- a/themes/finc/templates/myresearch/acquisition.phtml +++ b/themes/finc/templates/myresearch/acquisition.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - acquisition --> <?php // Set up page title: -$this->headTitle($this->translate('PDA::pda_form_title') . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('PDA::pda_form_title')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('PDA::pda_form_title') . '</li>'; diff --git a/themes/finc/templates/myresearch/cataloglogin.phtml b/themes/finc/templates/myresearch/cataloglogin.phtml index 1f89d9181e8f2d8788f28707721dfd0244ffc9fa..0ae0ff0c85d5f04b38dacde8f2ea2eb076b066f0 100644 --- a/themes/finc/templates/myresearch/cataloglogin.phtml +++ b/themes/finc/templates/myresearch/cataloglogin.phtml @@ -1,6 +1,6 @@ <?php // Set up page title: - $this->headTitle($this->translate('Login') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Login')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Login') . '</li>'; diff --git a/themes/finc/templates/myresearch/checkedout.phtml b/themes/finc/templates/myresearch/checkedout.phtml index da91dd35e27a562a426a54b8bf6fd13452ec3339..a6b6773c1a96c29bef8e5892db1ffae744b4d08a 100644 --- a/themes/finc/templates/myresearch/checkedout.phtml +++ b/themes/finc/templates/myresearch/checkedout.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - checkedout --> <?php // Set up page title: - $this->headTitle($this->translate('Checked Out Items') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Checked Out Items')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Checked Out Items') . '</li>'; diff --git a/themes/finc/templates/myresearch/edit.phtml b/themes/finc/templates/myresearch/edit.phtml index 71a923eaa555fe996483ffe554ab969699d7d453..0484ff434fbfb08d8b1806970c946cb7d0545bd3 100644 --- a/themes/finc/templates/myresearch/edit.phtml +++ b/themes/finc/templates/myresearch/edit.phtml @@ -3,7 +3,7 @@ <?php // Set up page title: - $this->headTitle($this->translate('Edit') . ' : ' . $this->driver->getBreadcrumb() . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Edit') . ' : ' . $this->driver->getBreadcrumb()); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Edit') . '</li>'; diff --git a/themes/finc/templates/myresearch/editlist.phtml b/themes/finc/templates/myresearch/editlist.phtml index 91994836d6b1db9cf7916e333b35a6874dc2fccb..929bb53ca801ed12daec205700970390de96cb04 100644 --- a/themes/finc/templates/myresearch/editlist.phtml +++ b/themes/finc/templates/myresearch/editlist.phtml @@ -4,7 +4,7 @@ <?php // Set up page title: $pageTitle = empty($this->list->id) ? 'Create a List' : "edit_list"; - $this->headTitle($this->translate($pageTitle) . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate($pageTitle)); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li>' diff --git a/themes/finc/templates/myresearch/fines.phtml b/themes/finc/templates/myresearch/fines.phtml index 2762ecb0504a0a1fad0987a38f3528daac1f03de..a4054ab251ff02135bbac77bc1fddac309500dbb 100644 --- a/themes/finc/templates/myresearch/fines.phtml +++ b/themes/finc/templates/myresearch/fines.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - fines --> <?php // Set up page title: - $this->headTitle($this->translate('My Fines') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('My Fines')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Fines') . '</li>'; diff --git a/themes/finc/templates/myresearch/historicloans.phtml b/themes/finc/templates/myresearch/historicloans.phtml index 16cf3c34b27a7a3cdadf23034fd3d30ced416536..44605abc8de8fafa023af8ba0b70903984ef3263 100644 --- a/themes/finc/templates/myresearch/historicloans.phtml +++ b/themes/finc/templates/myresearch/historicloans.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - historicloans --> <?php // Set up page title: - $this->headTitle($this->translate('Loan History') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Loan History')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Loan History') . '</li>'; diff --git a/themes/finc/templates/myresearch/holds.phtml b/themes/finc/templates/myresearch/holds.phtml index 7131cf6092de4f611c1d37361391d1bf7d624ee6..6b584c7355cd127ed8e15dc3c689e737e098636d 100644 --- a/themes/finc/templates/myresearch/holds.phtml +++ b/themes/finc/templates/myresearch/holds.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - holds --> <?php // Set up page title: - $this->headTitle($this->translate('My Holds') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('My Holds')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('My Holds') . '</li>'; diff --git a/themes/finc/templates/myresearch/illrequests.phtml b/themes/finc/templates/myresearch/illrequests.phtml index 27320ac4a5b5bfea69fdd1a80ce8ed1f5bbba97d..6f87f860b07bdb742a7a115a18a82eabeb1a8a79 100644 --- a/themes/finc/templates/myresearch/illrequests.phtml +++ b/themes/finc/templates/myresearch/illrequests.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - illrequests --> <?php // Set up page title: - $this->headTitle($this->translate('Interlibrary Loan Requests') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Interlibrary Loan Requests')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li>' diff --git a/themes/finc/templates/myresearch/mylist.phtml b/themes/finc/templates/myresearch/mylist.phtml index f210befcf16ca777958f1b0fc3c1fdfba48dbb41..6354ae6aa1c7962981d456fc50ba0388082b6014 100644 --- a/themes/finc/templates/myresearch/mylist.phtml +++ b/themes/finc/templates/myresearch/mylist.phtml @@ -4,7 +4,7 @@ $list = $this->results->getListObject(); // Set up page title: -$this->headTitle(isset($list) ? $list->title : $this->translate('Favorites') . ' | ' . $this->translate("LibraryName")); +$this->headTitle(isset($list) ? $list->title : $this->translate('Favorites')); // Set up breadcrumbs: $currPage = isset($list) ? 'List' : 'Favorites'; diff --git a/themes/finc/templates/myresearch/newpassword.phtml b/themes/finc/templates/myresearch/newpassword.phtml index 713a5234ad4e995b5c03bce04913431e447a46bd..b2102e7315a77aac2af970fed31039ebc427488a 100644 --- a/themes/finc/templates/myresearch/newpassword.phtml +++ b/themes/finc/templates/myresearch/newpassword.phtml @@ -1,7 +1,7 @@ <!-- finc - templates - myresearch - newpassword --> <?php // Set up page title: - $this->headTitle($this->translate('Create New Password') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Create New Password')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li>' diff --git a/themes/finc/templates/myresearch/profile.phtml b/themes/finc/templates/myresearch/profile.phtml index e3ad22b6eee0b6e85635afc077f9a5b98002452a..8360cd61d7bb948c9826c2a4ef1c035eaa4718fe 100644 --- a/themes/finc/templates/myresearch/profile.phtml +++ b/themes/finc/templates/myresearch/profile.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - profile --> <?php // Set up page title: - $this->headTitle($this->translate('My Profile') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('My Profile')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Profile') . '</li>'; diff --git a/themes/finc/templates/myresearch/storageretrievalrequests.phtml b/themes/finc/templates/myresearch/storageretrievalrequests.phtml index 7b34bcd48b0cd96bc58d09608690c419f73e3a9e..a7ec9c253467e5a0395fceac4257cbfb79c20a62 100644 --- a/themes/finc/templates/myresearch/storageretrievalrequests.phtml +++ b/themes/finc/templates/myresearch/storageretrievalrequests.phtml @@ -1,7 +1,7 @@ <!-- finc: myresearch - storageretrievalrequests --> <?php // Set up page title: - $this->headTitle($this->translate('Storage Retrieval Requests') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Storage Retrieval Requests')); // Set up breadcrumbs: $this->layout()->breadcrumbs = '<li><a href="' . $this->url('myresearch-home') . '">' . $this->transEsc('Your Account') . '</a></li> <li class="active">' . $this->transEsc('Storage Retrieval Requests') . '</li>'; diff --git a/themes/finc/templates/search/advanced/layout.phtml b/themes/finc/templates/search/advanced/layout.phtml index a4e70ff5492cf39cdeac32fda623cb86ecd2e3a5..350eabbcb32299defd5719084c250809c70a3ffc 100644 --- a/themes/finc/templates/search/advanced/layout.phtml +++ b/themes/finc/templates/search/advanced/layout.phtml @@ -1,7 +1,7 @@ <!-- finc: search - advanced - layout --> <?php // Set page title. -$this->headTitle($this->translate('Advanced Search') . ' | ' . $this->translate("LibraryName")); +$this->headTitle($this->translate('Advanced Search')); // Disable top search box -- this page has a special layout. $this->layout()->searchbox = false; diff --git a/themes/finc/templates/search/history.phtml b/themes/finc/templates/search/history.phtml index e5a71ac83b056b1722c83e26f6dfd9ce54a87310..04a7ee298e0aba39bd1d24479b4888e5c268933f 100644 --- a/themes/finc/templates/search/history.phtml +++ b/themes/finc/templates/search/history.phtml @@ -1,7 +1,7 @@ <!-- finc - templates - search - history --> <?php // Set page title. - $this->headTitle($this->translate('Search History') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Search History')); $loginEnabled = is_object($account = $this->auth()->getManager()) && $account->loginEnabled(); diff --git a/themes/finc/templates/search/home.phtml b/themes/finc/templates/search/home.phtml index 781d4415bfc0377c3800d58c1f039a9aabecc575..4fc8d20045f806bc73c723704385410dd97f7cd5 100644 --- a/themes/finc/templates/search/home.phtml +++ b/themes/finc/templates/search/home.phtml @@ -1,7 +1,7 @@ <!-- finc: search - home --> <?php // Set page title. - $this->headTitle($this->translate('Search Home') . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Search Home')); // finc: disable top search box here if you want the old look, see also below // $this->layout()->searchbox = false; diff --git a/themes/finc/templates/search/results.phtml b/themes/finc/templates/search/results.phtml index 57048aa134330644849f05c4053b886b44022015..de9ade6fd08919a365af15829592376107b95f24 100644 --- a/themes/finc/templates/search/results.phtml +++ b/themes/finc/templates/search/results.phtml @@ -7,7 +7,7 @@ $lookfor = $this->results->getUrlQuery()->isQuerySuppressed() ? '' : $this->para if (isset($this->overrideTitle)) { $this->headTitle($this->overrideTitle); } else { - $this->headTitle($this->translate('Search Results') . (empty($lookfor) ? '' : " - {$lookfor}") . ' | ' . $this->translate("LibraryName")); + $this->headTitle($this->translate('Search Results') . (empty($lookfor) ? '' : " - {$lookfor}")); } // Set up search box: diff --git a/themes/finc/theme.config.php b/themes/finc/theme.config.php index 3896a57fa8beb2d1e681c1a4b599d47299116f8c..c20700c8971b8c09e40fc3d0cd8e4d267cf4477d 100644 --- a/themes/finc/theme.config.php +++ b/themes/finc/theme.config.php @@ -18,7 +18,6 @@ return [ 'recordLink' => 'finc\View\Helper\Root\RecordLink', 'record' => 'finc\View\Helper\Root\Record', 'flashmessages' => 'finc\View\Helper\Root\Flashmessages', - 'headTitle' => 'finc\View\Helper\Root\HeadTitle', 'externalLink' => 'finc\View\Helper\Root\ExternalLink', ], 'factories' => [ @@ -44,8 +43,6 @@ return [ 'VuFind\View\Helper\Root\ResultFeedFactory', 'finc\View\Helper\Root\Flashmessages' => 'VuFind\View\Helper\Root\FlashmessagesFactory', - 'finc\View\Helper\Root\HeadTitle' => - 'finc\View\Helper\Root\Factory::getHeadTitle', 'finc\View\Helper\Root\ExternalLink' => 'finc\View\Helper\Root\Factory::getExternalLink', ]