Whoops \ Exception \ ErrorException (E_WARNING)
Cannot use a scalar value as an array Whoops\Exception\ErrorException thrown with message "Cannot use a scalar value as an array" Stacktrace: #5 Whoops\Exception\ErrorException in /home/ski2freedom/public_html/site/plugins/imagekit/lib/lazythumb.php:133 #4 Whoops\Run:handleError in /home/ski2freedom/public_html/site/plugins/imagekit/lib/lazythumb.php:133 #3 Kirby\Plugins\ImageKit\LazyThumb:process in /home/ski2freedom/public_html/site/plugins/imagekit/lib/component/thumb.php:66 #2 Kirby\Plugins\ImageKit\Component\Thumb:Kirby\Plugins\ImageKit\Component\{closure} in /home/ski2freedom/public_html/kirby/vendor/getkirby/toolkit/helpers.php:282 #1 call in /home/ski2freedom/public_html/kirby/kirby.php:743 #0 Kirby:launch in /home/ski2freedom/public_html/index.php:16
Stack frames (6)
5
Whoops
\
Exception
\
ErrorException
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
lazythumb.php
133
4
Whoops
\
Run
handleError
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
lazythumb.php
133
3
Kirby
\
Plugins
\
ImageKit
\
LazyThumb
process
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
component
/
thumb.php
66
2
Kirby
\
Plugins
\
ImageKit
\
Component
\
Thumb
Kirby
\
Plugins
\
ImageKit
\
Component
\
{closure}
/
vendor
/
getkirby
/
toolkit
/
helpers.php
282
1
call
/
kirby.php
743
0
Kirby
launch
/
home
/
ski2freedom
/
public_html
/
index.php
16
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
lazythumb.php
    if(!str::startsWith($path, $thumbs)) {
      $path = $thumbs . DS . $path;
    }
    
    $jobfile = static::jobfile($path);
    
    if(!$thumbinfo = @include($jobfile)) {
      // Abort, if there is no matching jobfile for the
      // requested thumb.
      return false;
    }
    
    // This option is a closure by default, which cannot be
    // restored. Currently, we can only restore it by
    // overriding it the the default option of the thumb
    // class. So this does not work, when a custom 
    // 'destination' option was set for this particular
    // thumbnail or the option has been changed between
    // jobfile creation and execution of this method.
    $thumbinfo['options']['destination'] = thumb::$defaults['destination'];
 
    if (!is_null($thumbinfo['source']['page'])) {
      // Try to relocate the image and get it’s association
      // with the original parent page or site
      if ($thumbinfo['source']['page'] === '') {
        // Image was uploaded to the "content" directory
        $image = site()->image($thumbinfo['source']['filename']);
      } else {
        // Image belongs to a specific page
        $image = page($thumbinfo['source']['page'])->image($thumbinfo['source']['filename']);
      }
      
      if(!$image) {
        // If source image does not exist any more, remove
        // the jobfile.
        f::remove($jobfile);
        return false;
      }
    } else {
      // If the image does not belong to a specific page,
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
lazythumb.php
    if(!str::startsWith($path, $thumbs)) {
      $path = $thumbs . DS . $path;
    }
    
    $jobfile = static::jobfile($path);
    
    if(!$thumbinfo = @include($jobfile)) {
      // Abort, if there is no matching jobfile for the
      // requested thumb.
      return false;
    }
    
    // This option is a closure by default, which cannot be
    // restored. Currently, we can only restore it by
    // overriding it the the default option of the thumb
    // class. So this does not work, when a custom 
    // 'destination' option was set for this particular
    // thumbnail or the option has been changed between
    // jobfile creation and execution of this method.
    $thumbinfo['options']['destination'] = thumb::$defaults['destination'];
 
    if (!is_null($thumbinfo['source']['page'])) {
      // Try to relocate the image and get it’s association
      // with the original parent page or site
      if ($thumbinfo['source']['page'] === '') {
        // Image was uploaded to the "content" directory
        $image = site()->image($thumbinfo['source']['filename']);
      } else {
        // Image belongs to a specific page
        $image = page($thumbinfo['source']['page'])->image($thumbinfo['source']['filename']);
      }
      
      if(!$image) {
        // If source image does not exist any more, remove
        // the jobfile.
        f::remove($jobfile);
        return false;
      }
    } else {
      // If the image does not belong to a specific page,
/
home
/
ski2freedom
/
public_html
/
site
/
plugins
/
imagekit
/
lib
/
component
/
thumb.php
    // thumbs directory.
    $base = ltrim(substr($this->kirby->roots->thumbs(), strlen($this->kirby->roots->index())), DS);
    
    // Setup optimizer if enabled.
    if($this->kirby->option('imagekit.optimize')) {
      optimizer::register();
    }
 
    $this->kirby->set('route', [
      'pattern' => "{$base}/(:all)", // $base = 'thumbs' by default
      'action'  => function ($path) {
        
        if($this->kirby->option('imagekit.complain')) {
          complainingthumb::enableSendError();
          complainingthumb::setErrorFormat('image');
        }
        
        // Try to load a jobfile for given thumb url and
        // execute if exists
        $thumb = lazythumb::process($path);
        
        if($thumb) {
          // Serve the image, if everything went fine :-D
          
          $root = $thumb->result->root();
 
          // Make sure, we’re sending a 200 status, telling
          // the browser that everything’s okay.
          header::status(200);
 
          // Don’t tell anyone that this image was just
          // created by PHP ;-)
          header_remove('X-Powered-By');
 
          header('Last-Modified: '  . gmdate('D, d M Y H:i:s', f::modified($root)) . ' GMT');
          header('Content-Type: '   . f::mime($root));
          header('Content-Length: ' . f::size($root));
 
          // Send file and stop script execution
          readfile($root);
/
home
/
ski2freedom
/
public_html
/
kirby
/
vendor
/
getkirby
/
toolkit
/
helpers.php
 
/**
 * Facepalm typo alias
 * @see csrf()
 */
function csfr() {
  return call('csrf', func_get_args());
}
 
/**
 * Shortcut for call_user_func_array with a better handling of arguments
 *
 * @param mixed $function
 * @param mixed $arguments
 * @return mixed
 */
function call($function, $arguments = array()) {
  if(!is_callable($function)) return false;
  if(!is_array($arguments)) $arguments = array($arguments);
  return call_user_func_array($function, $arguments);
}
 
/**
 * Parses yaml structured text
 *
 * @param $string
 * @return array
 */
function yaml($string) {
  return yaml::decode($string);
}
 
/**
 * Simple email sender helper
 *
 * @param array $params
 * @return Email
 */
function email($params = array()) {
  return new Email($params);
/
home
/
ski2freedom
/
public_html
/
kirby
/
kirby.php
 
    // load all plugins
    $this->plugins();
 
    // start the router
    $this->router = new Router($this->routes());
    $this->route  = $this->router->run(trim($this->path(), '/'));
 
    // check for a valid route
    if(is_null($this->route)) {
      header::status('500');
      header::type('json');
      die(json_encode(array(
        'status'  => 'error',
        'message' => 'Invalid route or request method'
      )));
    }
 
    // call the router action with all arguments from the pattern
    $response = call($this->route->action(), $this->route->arguments());
 
    // load all language variables
    // this can only be loaded once the router action has been called
    // otherwise the current language is not yet available
    $this->localize();
 
    // build the response
    $this->response = $this->component('response')->make($response);
 
    // store the current language in the session
    if(
        $this->option('language.detect') &&
        $this->site()->multilang() &&
        $this->site()->language()
      ) {
      s::set('kirby_language', $this->site()->language()->code());
    }
 
    return $this->response;
 
/
home
/
ski2freedom
/
public_html
/
index.php
<?php
 
define('DS', DIRECTORY_SEPARATOR);
 
// load kirby
require(__DIR__ . DS . 'kirby' . DS . 'bootstrap.php');
 
// check for a custom site.php
if(file_exists(__DIR__ . DS . 'site.php')) {
  require(__DIR__ . DS . 'site.php');
} else {
  $kirby = kirby();
}
 
// render
echo $kirby->launch();

Environment & details:

Key Value
Kirby Toolkit v2.5.10
Kirby CMS v2.5.10
empty
empty
empty
empty
empty
Key Value
USER ski2freedom
HOME /home/ski2freedom
SCRIPT_NAME /index.php
REQUEST_URI /thumbs/locations-europe/france/morzine/photo-gallery/fr-morzine-o-du-t-norwegian-press-800x600-q80.jpg
QUERY_STRING
REQUEST_METHOD GET
SERVER_PROTOCOL HTTP/2.0
GATEWAY_INTERFACE CGI/1.1
REDIRECT_URL /thumbs/locations-europe/france/morzine/photo-gallery/fr-morzine-o-du-t-norwegian-press-800x600-q80.jpg
REMOTE_PORT 49845
SCRIPT_FILENAME /home/ski2freedom/public_html/index.php
SERVER_ADMIN root@localhost
CONTEXT_DOCUMENT_ROOT /home/ski2freedom/public_html
CONTEXT_PREFIX
REQUEST_SCHEME https
DOCUMENT_ROOT /home/ski2freedom/public_html
REMOTE_ADDR 3.15.147.53
SERVER_PORT 443
SERVER_ADDR 192.168.0.114
SERVER_NAME ski2freedom.com
SERVER_SOFTWARE Apache
SERVER_SIGNATURE
PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin
HTTP_HOST ski2freedom.com
HTTP_REFERER http://ski2freedom.com/thumbs/locations-europe/france/morzine/photo-gallery/fr-morzine-o-du-t-norwegian-press-800x600-q80.jpg
HTTP_USER_AGENT claudebot
HTTP_ACCEPT */*
proxy-nokeepalive 1
H2_STREAM_TAG 000
H2_STREAM_ID
H2_PUSHED_ON
H2_PUSHED
H2_PUSH off
H2PUSH off
HTTP2 on
SSL_TLS_SNI ski2freedom.com
HTTPS on
UNIQUE_ID ZiFRZdn@cLtNM68hPjSPiwABjQA
REDIRECT_STATUS 200
REDIRECT_H2_STREAM_TAG 000
REDIRECT_H2_STREAM_ID
REDIRECT_H2_PUSHED_ON
REDIRECT_H2_PUSHED
REDIRECT_H2_PUSH off
REDIRECT_H2PUSH off
REDIRECT_HTTP2 on
REDIRECT_SSL_TLS_SNI ski2freedom.com
REDIRECT_HTTPS on
REDIRECT_UNIQUE_ID ZiFRZdn@cLtNM68hPjSPiwABjQA
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1713459557.8898
REQUEST_TIME 1713459557
empty
0. Whoops\Handler\PrettyPageHandler