Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_021a0e8b6f502293d5a50e594a62fecc in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_021a0e8b6f502293d5a50e594a62fecc): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_08a84308b476c26bb5e13352693aa02c in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_08a84308b476c26bb5e13352693aa02c): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_0a5fd174ebefd055f01ac50c410fbfa0 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_0a5fd174ebefd055f01ac50c410fbfa0): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_0a6013a82b40447b6e58cf1eec2fcf28 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_0a6013a82b40447b6e58cf1eec2fcf28): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_0f18639aa0ee5d5401c3b053c0f95066 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_0f18639aa0ee5d5401c3b053c0f95066): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_149558c8087b113f16f1a9d44c2a2371 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_149558c8087b113f16f1a9d44c2a2371): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_264a351106f9e86d1c7149b0f29273fc in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_264a351106f9e86d1c7149b0f29273fc): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_280d461c6e580192be0427ebbfc1bc37 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_280d461c6e580192be0427ebbfc1bc37): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_2fefd4e84da105d3724032946c83b223 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_2fefd4e84da105d3724032946c83b223): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_357b48189d9b2438dfb666379ef3d20a in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_357b48189d9b2438dfb666379ef3d20a): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_4df270697cf869d72a89c2133c920830 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_4df270697cf869d72a89c2133c920830): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_51f3549f85a33c56fabca2af1564857b in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_51f3549f85a33c56fabca2af1564857b): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_53dc7d75127864b110fa65b92868f940 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_53dc7d75127864b110fa65b92868f940): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_65a12a41385d1459af0f042ba733ba2e in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_65a12a41385d1459af0f042ba733ba2e): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_686a8f8d3c901b10a3156c759cdb9d58 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_686a8f8d3c901b10a3156c759cdb9d58): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_77370b453a17edf038baaa2b58350f3c in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_77370b453a17edf038baaa2b58350f3c): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_78c4dd35fcf3c00882c5da2c070c4c4d in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_78c4dd35fcf3c00882c5da2c070c4c4d): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_7f0118dc1d0eeed843649a16a7bd7290 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_7f0118dc1d0eeed843649a16a7bd7290): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_99d1d48475a0914bec718e3ed6fa31f2 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_99d1d48475a0914bec718e3ed6fa31f2): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_9b3cb6caa4d147116c7ca19225a022ce in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_9b3cb6caa4d147116c7ca19225a022ce): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_9f482c3e3236089e29cfad8e8072629e in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_9f482c3e3236089e29cfad8e8072629e): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_9f75bbb667c3802bdf5cd8f0976ff5ee in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_9f75bbb667c3802bdf5cd8f0976ff5ee): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_ad5f3016091e325f4994669380be19b3 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_ad5f3016091e325f4994669380be19b3): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_ae15f71ec7dbe5d3a171da2853fd209c in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_ae15f71ec7dbe5d3a171da2853fd209c): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_aef5b4808c149b043cdaa0a904b9fc19 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_aef5b4808c149b043cdaa0a904b9fc19): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_b133bbb331f67e4f5d92802239a6aceb in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_b133bbb331f67e4f5d92802239a6aceb): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_b8797fa7b09c5d0a50b8a4a8e9157942 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_b8797fa7b09c5d0a50b8a4a8e9157942): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_c0f8f19e772172c75c310a69a32dfdcd in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_c0f8f19e772172c75c310a69a32dfdcd): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_c108345b8235b59ab5c120d21113fe28 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_c108345b8235b59ab5c120d21113fe28): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_c9b623a5e9f4379a40926491b53846bb in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_c9b623a5e9f4379a40926491b53846bb): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_cbac50012e6d2bffa478f4b5a538f575 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_cbac50012e6d2bffa478f4b5a538f575): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_d1c7d59d95c273bd7a7f9416428e2267 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_d1c7d59d95c273bd7a7f9416428e2267): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_d1f7d8b965a6c348a14f78c1558a7c0b in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_d1f7d8b965a6c348a14f78c1558a7c0b): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_d489fc24bc49eeda20f2bfe714c2a4fb in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_d489fc24bc49eeda20f2bfe714c2a4fb): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_d88643d6b943066f28bf5e0f3a596747 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_d88643d6b943066f28bf5e0f3a596747): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_d911dcffa0f7e3f5fcb17b92d687baec in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_d911dcffa0f7e3f5fcb17b92d687baec): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_f0df33b2604482eaefce44bb7ccc79bb in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_f0df33b2604482eaefce44bb7ccc79bb): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_f811ec0f4e894dc051b68e05aa6eacf4 in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_f811ec0f4e894dc051b68e05aa6eacf4): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_f820523461d7f711e314f2704602b0dd in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_f820523461d7f711e314f2704602b0dd): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: filemtime(): stat failed for /tmp/vufind_sessions/sess_f9cbc6d45b04f599d07e2bdf4a7a9c7f in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 137

Warning: unlink(/tmp/vufind_sessions/sess_f9cbc6d45b04f599d07e2bdf4a7a9c7f): No such file or directory in /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php on line 138

Warning: session_start(): Session cache limiter cannot be sent after headers have already been sent (output started at /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php:137) in /usr/local/vufind/vendor/laminas/laminas-session/src/SessionManager.php on line 144
Whoops! There was an error.
Whoops \ Exception \ ErrorException (E_WARNING)
Cannot modify header information - headers already sent by (output started at /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php:137) Whoops\Exception\ErrorException thrown with message "Cannot modify header information - headers already sent by (output started at /usr/local/vufind/module/VuFind/src/VuFind/Session/File.php:137)" Stacktrace: #10 Whoops\Exception\ErrorException in /usr/local/vufind/module/VuFind/src/VuFind/Cookie/CookieManager.php:233 #9 setcookie in /usr/local/vufind/module/VuFind/src/VuFind/Cookie/CookieManager.php:233 #8 VuFind\Cookie\CookieManager:proxySetCookie in /usr/local/vufind/module/VuFind/src/VuFind/Cookie/CookieManager.php:265 #7 VuFind\Cookie\CookieManager:setGlobalCookie in /usr/local/vufind/module/VuFind/src/VuFind/Cookie/CookieManager.php:315 #6 VuFind\Cookie\CookieManager:set in /usr/local/vufind/module/VuFindTheme/src/VuFindTheme/Initializer.php:229 #5 VuFindTheme\Initializer:pickTheme in /usr/local/vufind/module/VuFindTheme/src/VuFindTheme/Initializer.php:167 #4 VuFindTheme\Initializer:init in /usr/local/vufind/module/VuFind/src/VuFind/Bootstrapper.php:240 #3 VuFind\Bootstrapper:VuFind\{closure} in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:319 #2 Laminas\EventManager\EventManager:triggerListeners in /usr/local/vufind/vendor/laminas/laminas-eventmanager/src/EventManager.php:179 #1 Laminas\EventManager\EventManager:triggerEventUntil in /usr/local/vufind/vendor/laminas/laminas-mvc/src/Application.php:325 #0 Laminas\Mvc\Application:run in /usr/local/vufind/public/index.php:16
10
Whoops\Exception\ErrorException
/module/VuFind/src/VuFind/Cookie/CookieManager.php233
9
setcookie
/module/VuFind/src/VuFind/Cookie/CookieManager.php233
8
VuFind\Cookie\CookieManager proxySetCookie
/module/VuFind/src/VuFind/Cookie/CookieManager.php265
7
VuFind\Cookie\CookieManager setGlobalCookie
/module/VuFind/src/VuFind/Cookie/CookieManager.php315
6
VuFind\Cookie\CookieManager set
/module/VuFindTheme/src/VuFindTheme/Initializer.php229
5
VuFindTheme\Initializer pickTheme
/module/VuFindTheme/src/VuFindTheme/Initializer.php167
4
VuFindTheme\Initializer init
/module/VuFind/src/VuFind/Bootstrapper.php240
3
VuFind\Bootstrapper VuFind\{closure}
/vendor/laminas/laminas-eventmanager/src/EventManager.php319
2
Laminas\EventManager\EventManager triggerListeners
/vendor/laminas/laminas-eventmanager/src/EventManager.php179
1
Laminas\EventManager\EventManager triggerEventUntil
/vendor/laminas/laminas-mvc/src/Application.php325
0
Laminas\Mvc\Application run
/public/index.php16
        $path,
        $domain,
        $secure,
        $httpOnly,
        $sameSite
    ) {
        // Special case: in CLI -- don't actually write headers!
        if ('cli' === PHP_SAPI) {
            return true;
        }
        return setcookie(
            $key,
            $value ?? '',
            [
                'expires' => $expire,
                'path' => $path,
                'domain' => $domain,
                'samesite' => $sameSite,
                'secure' => $secure,
                'httponly' => $httpOnly,
            ]
        );
    }
 
    /**
     * Support method for set() -- set the actual cookie in PHP.
     *
     * @param string    $key      Name of cookie to set
     * @param mixed     $value    Value to set
     * @param int       $expire   Cookie expiration time
     * @param null|bool $httpOnly Whether the cookie should be "HTTP only"
     * @param string    $sameSite SameSite attribute to use (Lax, Strict or None)
     *
     * @return bool
     */
    public function setGlobalCookie(
        $key,
        $value,
        $expire,
        $httpOnly = null,
        $path,
        $domain,
        $secure,
        $httpOnly,
        $sameSite
    ) {
        // Special case: in CLI -- don't actually write headers!
        if ('cli' === PHP_SAPI) {
            return true;
        }
        return setcookie(
            $key,
            $value ?? '',
            [
                'expires' => $expire,
                'path' => $path,
                'domain' => $domain,
                'samesite' => $sameSite,
                'secure' => $secure,
                'httponly' => $httpOnly,
            ]
        );
    }
 
    /**
     * Support method for set() -- set the actual cookie in PHP.
     *
     * @param string    $key      Name of cookie to set
     * @param mixed     $value    Value to set
     * @param int       $expire   Cookie expiration time
     * @param null|bool $httpOnly Whether the cookie should be "HTTP only"
     * @param string    $sameSite SameSite attribute to use (Lax, Strict or None)
     *
     * @return bool
     */
    public function setGlobalCookie(
        $key,
        $value,
        $expire,
        $httpOnly = null,
     *
     * @return bool
     */
    public function setGlobalCookie(
        $key,
        $value,
        $expire,
        $httpOnly = null,
        $sameSite = null
    ) {
        if (null === $httpOnly) {
            $httpOnly = $this->httpOnly;
        }
        if (null === $sameSite) {
            $sameSite = $this->sameSite;
        }
        // Simple case: flat value.
        if (!is_array($value)) {
            return $this->proxySetCookie(
                $key,
                $value,
                $expire,
                $this->path,
                $this->domain,
                $this->secure,
                $httpOnly,
                $sameSite
            );
        }
 
        // Complex case: array of values.
        $success = true;
        foreach ($value as $i => $curr) {
            $lastSuccess = $this->proxySetCookie(
                $key . '[' . $i . ']',
                $curr,
                $expire,
                $this->path,
                $this->domain,
                $this->secure,
    /**
     * Set a cookie.
     *
     * @param string    $key      Name of cookie to set
     * @param mixed     $value    Value to set
     * @param int       $expire   Cookie expiration time
     * @param null|bool $httpOnly Whether the cookie should be "HTTP only"
     * @param string    $sameSite SameSite attribute to use (Lax, Strict or None)
     *
     * @return bool
     */
    public function set(
        $key,
        $value,
        $expire = 0,
        $httpOnly = null,
        $sameSite = null
    ) {
        $success = $this
            ->setGlobalCookie($key, $value, $expire, $httpOnly, $sameSite);
        if ($success) {
            $this->cookies[$key] = $value;
        }
        return $success;
    }
 
    /**
     * Clear a cookie.
     *
     * @param string $key Name of cookie to unset
     *
     * @return bool
     */
    public function clear($key)
    {
        $value = $this->get($key);
        if (is_array($value)) {
            $success = true;
            foreach (array_keys($value) as $i) {
                if (!$this->clear($key . '[' . $i . ']')) {
            ? $this->config->mobile_theme : false;
 
        // Find out if the user has a saved preference in the POST, URL or cookies:
        $selectedUI = null;
        if (isset($request)) {
            $selectedUI = $request->getPost()->get(
                'ui',
                $request->getQuery()->get(
                    'ui',
                    $request->getCookie()->ui ?? null
                )
            );
        }
        if (empty($selectedUI)) {
            $selectedUI = ($mobileTheme && $this->mobile->detect())
                ? 'mobile' : 'standard';
        }
 
        // Save the current setting to a cookie so it persists:
        $this->cookieManager->set('ui', $selectedUI);
 
        // Do we have a valid mobile selection?
        if ($mobileTheme && $selectedUI == 'mobile') {
            return $mobileTheme;
        }
 
        // Do we have a non-standard selection?
        if (
            $selectedUI != 'standard'
            && isset($this->config->alternate_themes)
        ) {
            // Check the alternate theme settings for a match:
            $parts = explode(',', $this->config->alternate_themes);
            foreach ($parts as $part) {
                $subparts = explode(':', $part);
                if (
                    (trim($subparts[0]) == trim($selectedUI))
                    && isset($subparts[1]) && !empty($subparts[1])
                ) {
                    return $subparts[1];
    }
 
    /**
     * Initialize the theme.  This needs to be triggered as part of the dispatch
     * event.
     *
     * @throws \Exception
     * @return void
     */
    public function init()
    {
        // Make sure to initialize the theme just once
        if (self::$themeInitialized) {
            return;
        }
        self::$themeInitialized = true;
 
        // Determine the current theme:
        $currentTheme = $this->pickTheme(
            isset($this->event) ? $this->event->getRequest() : null
        );
 
        // Determine theme options:
        $this->sendThemeOptionsToView();
 
        // Make sure the current theme is set correctly in the tools object:
        $error = null;
        try {
            $this->tools->setTheme($currentTheme);
        } catch (\Exception $error) {
            // If an illegal value is passed in, the setter may throw an exception.
            // We should ignore it for now and throw it after we have set up the
            // theme (the setter will use a safe value instead of the illegal one).
        }
 
        // Using the settings we initialized above, actually configure the themes; we
        // need to do this even if there is an error, since we need a theme in order
        // to display an error message!
        $this->setUpThemes(array_reverse($this->tools->getThemeInfo()));
 
            ($user = $authManager->isLoggedIn())
            && $user->last_language != $language
        ) {
            $user->updateLastLanguage($language);
        }
    }
 
    /**
     * Set up theme handling.
     *
     * @return void
     */
    protected function initTheme(): void
    {
        // Attach remaining theme configuration to the dispatch event at high
        // priority (TODO: use priority constant once defined by framework):
        $config = $this->config->Site;
        $callback = function ($event) use ($config) {
            $theme = new \VuFindTheme\Initializer($config, $event);
            $theme->init();
        };
        $this->events->attach('dispatch.error', $callback, 9000);
        $this->events->attach('dispatch', $callback, 9000);
    }
 
    /**
     * Set up custom HTTP status based on exception information.
     *
     * @return void
     */
    protected function initExceptionBasedHttpStatuses(): void
    {
        // HTTP statuses not needed in console mode:
        if (PHP_SAPI == 'cli') {
            return;
        }
 
        $callback = function ($e) {
            $exception = $e->getParam('exception');
            if ($exception instanceof \VuFind\Exception\HttpStatusInterface) {
        }
 
        if ($this->sharedManager) {
            foreach ($this->sharedManager->getListeners($this->identifiers, $name) as $priority => $listeners) {
                $listOfListenersByPriority[$priority][] = $listeners;
            }
        }
 
        // Sort by priority in reverse order
        krsort($listOfListenersByPriority);
 
        // Initial value of stop propagation flag should be false
        $event->stopPropagation(false);
 
        // Execute listeners
        $responses = new ResponseCollection();
        foreach ($listOfListenersByPriority as $listOfListeners) {
            foreach ($listOfListeners as $listeners) {
                foreach ($listeners as $listener) {
                    $response = $listener($event);
                    $responses->push($response);
 
                    // If the event was asked to stop propagating, do so
                    if ($event->propagationIsStopped()) {
                        $responses->setStopped(true);
                        return $responses;
                    }
 
                    // If the result causes our validation callback to return true,
                    // stop propagation
                    if ($callback && $callback($response)) {
                        $responses->setStopped(true);
                        return $responses;
                    }
                }
            }
        }
 
        return $responses;
    }
            $event->setParams($argv);
        }
 
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEvent(EventInterface $event)
    {
        return $this->triggerListeners($event);
    }
 
    /**
     * @inheritDoc
     */
    public function triggerEventUntil(callable $callback, EventInterface $event)
    {
        return $this->triggerListeners($event, $callback);
    }
 
    /**
     * @inheritDoc
     */
    public function attach($eventName, callable $listener, $priority = 1)
    {
        if (! is_string($eventName)) {
            throw new Exception\InvalidArgumentException(sprintf(
                '%s expects a string for the event; received %s',
                __METHOD__,
                is_object($eventName) ? get_class($eventName) : gettype($eventName)
            ));
        }
 
        $this->events[$eventName][(int) $priority][0][] = $listener;
        return $listener;
    }
 
    /**
            $response = $result->last();
            if ($response instanceof ResponseInterface) {
                $event->setName(MvcEvent::EVENT_FINISH);
                $event->setTarget($this);
                $event->setResponse($response);
                $event->stopPropagation(false); // Clear before triggering
                $events->triggerEvent($event);
                $this->response = $response;
                return $this;
            }
        }
 
        if ($event->getError()) {
            return $this->completeRequest($event);
        }
 
        // Trigger dispatch event
        $event->setName(MvcEvent::EVENT_DISPATCH);
        $event->stopPropagation(false); // Clear before triggering
        $result = $events->triggerEventUntil($shortCircuit, $event);
 
        // Complete response
        $response = $result->last();
        if ($response instanceof ResponseInterface) {
            $event->setName(MvcEvent::EVENT_FINISH);
            $event->setTarget($this);
            $event->setResponse($response);
            $event->stopPropagation(false); // Clear before triggering
            $events->triggerEvent($event);
            $this->response = $response;
            return $this;
        }
 
        $response = $this->response;
        $event->setResponse($response);
        return $this->completeRequest($event);
    }
 
    /**
     * Complete the request
<?php
 
// If the profiler is enabled, set it up now:
$vufindProfiler = getenv('VUFIND_PROFILER_XHPROF');
if (!empty($vufindProfiler)) {
    include __DIR__ . '/../module/VuFind/functions/profiler.php';
    enableVuFindProfiling($vufindProfiler);
}
 
// Run the application!
$app = include __DIR__ . '/../config/application.php';
if (PHP_SAPI === 'cli') {
    return $app->getServiceManager()
        ->get(\VuFindConsole\ConsoleRunner::class)->run();
} else {
    $app->run();
}
 

Environment & details:

empty
empty
empty
empty
Key Value
__Laminas Array ( [_REQUEST_ACCESS_TIME] => 1714703269.8576 [_VALID] => Array ( [Laminas\Session\Validator\Id] => ) )
SessionState Laminas\Stdlib\ArrayObject Object ( [storage:protected] => Array ( [cookiePath] => / [sessionStartTime] => 1714703269 ) [flag:protected] => 2 [iteratorClass:protected] => ArrayIterator [protectedProperties:protected] => Array ( [0] => storage [1] => flag [2] => iteratorClass [3] => protectedProperties ) )
Key Value
REDIRECT_VUFIND_ENV development
REDIRECT_VUFIND_LOCAL_DIR /usr/local/vufind/local
REDIRECT_STATUS 200
VUFIND_ENV development
VUFIND_LOCAL_DIR /usr/local/vufind/local
HTTP_HOST catalog.spokanelibrary.org
HTTP_CONNECTION close
HTTP_X_REAL_IP 3.12.108.236
HTTP_X_FORWARDED_FOR 3.12.108.236
HTTP_X_FORWARDED_PROTO https
HTTP_X_FORWARDED_SSL on
HTTP_X_FORWARDED_PORT 443
HTTP_X_ORIGINAL_URI /catalog/Record/cc463dd7-96e1-5603-8f4b-0ddf95c39606
HTTP_ACCEPT */*
HTTP_USER_AGENT Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/composer2/vendor/bin:/root/composer1/vendor/bin
SERVER_SIGNATURE <address>Apache/2.4.56 (Debian) Server at catalog.spokanelibrary.org Port 80</address>
SERVER_SOFTWARE Apache/2.4.56 (Debian)
SERVER_NAME catalog.spokanelibrary.org
SERVER_ADDR 172.21.0.24
SERVER_PORT 80
REMOTE_ADDR 172.21.0.9
DOCUMENT_ROOT /var/www/html
REQUEST_SCHEME http
CONTEXT_PREFIX /catalog
CONTEXT_DOCUMENT_ROOT /usr/local/vufind/public
SERVER_ADMIN webmaster@localhost
SCRIPT_FILENAME /usr/local/vufind/public/index.php
REMOTE_PORT 60212
REDIRECT_URL /catalog/Record/cc463dd7-96e1-5603-8f4b-0ddf95c39606
GATEWAY_INTERFACE CGI/1.1
SERVER_PROTOCOL HTTP/1.1
REQUEST_METHOD GET
QUERY_STRING
REQUEST_URI /catalog/Record/cc463dd7-96e1-5603-8f4b-0ddf95c39606
SCRIPT_NAME /catalog/index.php
PHP_SELF /catalog/index.php
REQUEST_TIME_FLOAT 1714703269.6729
REQUEST_TIME 1714703269
argv Array ( )
argc 0
Key Value
HOSTNAME 383091efdb19
PHP_VERSION 8.0.29
APACHE_CONFDIR /etc/apache2
PHP_INI_DIR /usr/local/etc/php
GPG_KEYS 1729F83938DA44E27BA0F4D3DBDB397470D12172 BFDDD28642824F8118EF77909B67A5C12229118F 2C16C765DBE54A088130F1BC4B9B5F600B55F3B4
PHP_LDFLAGS -Wl,-O1 -pie
VUFIND_LOCAL_DIR /usr/local/vufind/local
PWD /var/www/html
APACHE_LOG_DIR /var/log/apache2
LANG C
PHP_SHA256 14db2fbf26c07d0eb2c9fab25dbde7e27726a3e88452cca671f0896bbb683ca9
APACHE_PID_FILE /var/run/apache2/apache2.pid
PHPIZE_DEPS autoconf dpkg-dev file g++ gcc libc-dev make pkg-config re2c
VIRTUAL_HOST vufind.spokanelibrary.org,catalog.spokanelibrary.org
PHP_URL https://www.php.net/distributions/php-8.0.29.tar.xz
APACHE_RUN_GROUP www-data
APACHE_LOCK_DIR /var/lock/apache2
VUFIND_LOCAL_MODULES SPLNewMaterials,SpokanePublic
SHLVL 0
COMPOSER_ALLOW_SUPERUSER 1
PHP_CFLAGS -fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
VUFIND_HOME /usr/local/vufind
APACHE_RUN_DIR /var/run/apache2
APACHE_ENVVARS /etc/apache2/envvars
APACHE_RUN_USER www-data
PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/composer2/vendor/bin:/root/composer1/vendor/bin
PHP_ASC_URL https://www.php.net/distributions/php-8.0.29.tar.xz.asc
COMPOSER_HOME /root/composer2
PHP_CPPFLAGS -fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
0. Whoops\Handler\PrettyPageHandler