Twig \ Error \ RuntimeError
An exception has been thrown during the rendering of a template ("Undefined array key 0").
Previous exceptions
  • Undefined array key 0 (2)
Twig\Error\RuntimeError thrown with message "An exception has been thrown during the rendering of a template ("Undefined array key 0")." Stacktrace: #15 Twig\Error\RuntimeError in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/views/index.html.twig:4 #14 Whoops\Exception\ErrorException in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/custom/TwigExtension.php:1248 #13 Gantry\Component\Whoops\SystemFacade:handleError in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/custom/TwigExtension.php:1248 #12 Gantry\Component\Twig\TwigExtension:checkColor in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/cache/gantry5/flurries_ash/twig/e3/e3cd4da5e79b1c93ccacfcd9b7704d47.php:46 #11 __TwigTemplate_6cd3c0c1167d5058a8f9da447c62b139:doDisplay in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/twig/twig/src/Template.php:405 #10 Twig\Template:displayWithErrorHandling in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/twig/twig/src/Template.php:378 #9 Twig\Template:display in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/twig/twig/src/Template.php:390 #8 Twig\Template:render in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/twig/twig/src/TemplateWrapper.php:45 #7 Twig\TemplateWrapper:render in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/timber/timber/lib/Loader.php:79 #6 Timber\Loader:render in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/timber/timber/lib/Timber.php:334 #5 Timber\Timber:compile in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/timber/timber/lib/Timber.php:383 #4 Timber\Timber:fetch in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/plugins/gantry5/vendor/timber/timber/lib/Timber.php:410 #3 Timber\Timber:render in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/index.php:164 #2 include in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-includes/template-loader.php:132 #1 require_once in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-blog-header.php:19 #0 require in /chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/index.php:17
Stack frames (16)
15
Twig\Error\RuntimeError
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/views/index.html.twig4
14
Whoops\Exception\ErrorException
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/custom/TwigExtension.php1248
13
Gantry\Component\Whoops\SystemFacade handleError
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/custom/TwigExtension.php1248
12
Gantry\Component\Twig\TwigExtension checkColor
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/cache/gantry5/flurries_ash/twig/e3/e3cd4da5e79b1c93ccacfcd9b7704d47.php46
11
__TwigTemplate_6cd3c0c1167d5058a8f9da447c62b139 doDisplay
…/vendor/twig/twig/src/Template.php405
10
Twig\Template displayWithErrorHandling
…/vendor/twig/twig/src/Template.php378
9
Twig\Template display
…/vendor/twig/twig/src/Template.php390
8
Twig\Template render
…/vendor/twig/twig/src/TemplateWrapper.php45
7
Twig\TemplateWrapper render
…/vendor/timber/timber/lib/Loader.php79
6
Timber\Loader render
…/vendor/timber/timber/lib/Timber.php334
5
Timber\Timber compile
…/vendor/timber/timber/lib/Timber.php383
4
Timber\Timber fetch
…/vendor/timber/timber/lib/Timber.php410
3
Timber\Timber render
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-content/themes/snowpage/index.php164
2
include
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-includes/template-loader.php132
1
require_once
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/wp-blog-header.php19
0
require
/chroot/home/ac0b36b7/bb6aeb0386.nxcli.io/html/index.php17
{% extends "partials/page.html.twig" %}
{% set twigTemplate = 'index.html.twig' %}
{% set scope = 'blog' %}
{% set melt = checkcolor(gantry.config.styles.inital.color) %}
 
{% block content %}
 
    <div class="platform-content">
        <div class="blog">
 
            {# Begin Page Header #}
            {% if gantry.config.get('content.' ~ scope ~ '.heading.enabled', '0') and gantry.config.get('content.' ~ scope ~ '.heading.text') is not empty %}
                <header class="page-header">
                    <h1>
                        {{ gantry.config.get('content.' ~ scope ~ '.heading.text') }}
                    </h1>
                </header>
            {% endif %}
            {# End Page Header #}
 
            {# Begin Post Entries #}
            <section class="entries">
                <div class="g-grid">
                    {% for post in posts %}
                        <div class="g-block {% if pagination.current == 1 and 'sticky' in post.class %}size-100{% else %}{{ gantry.config.get('content.' ~ scope ~ '.content.columns')|default('size-100') }}{% endif %}">
                            {% include ['partials/content-' ~ scope ~ '.html.twig', (post.format) ? 'partials/content-' ~ post.format ~ '.html.twig' : '', 'partials/content.html.twig'] %}
                        </div>
                    {% endfor %}
                </div>
            </section>
            {# End Post Entries #}
 
            {# Begin Pagination #}
            {% if pagination.pages and pagination.pages|length > 1 %}
                {% include 'partials/pagination.html.twig' %}
            {% endif %}
            {# End Pagination #}
 
        </div>
    </div>
                    break;
            }
 
            return;
        }
 
        /** 
        * @param hex $indexcolor
        */
        public function checkColor( $indexcolor ) {
            $colorlist = get_option('graupel_color');
            if ($colorlist != $indexcolor) {
                $colorname = array('#730b0b' => 'Coffee Brick', '#72160b' => 'Rouge Bourgogne', '#711d0b' => 'Berry', '#70230b' => 'Cinnamon', '#6f280b' => 'Cold Press Coffee', '#6e2d0a' => 'Seal Brown', '#6d310a' => 'Caramel', '#6c340a' => 'Sepia', '#6b380a' => 'Philippine Bronze', '#6a3b0a' => 'Colorado', '#69400a' => 'Violin Brown', '#67440a' => 'Saddlebrown', '#66480a' => 'Terre Sienne', '#644b0a' => 'Very Coffee', '#624f09' => 'Ayahuasca Vine', '#615209' => 'Olive Brown', '#5f5609' => 'Antique Bronze', '#5e5909' => 'Saratoga', '#5c5c09' => 'Brussels Sprout', '#595d09' => 'Douro', '#575d09' => 'Forestial Outpost', '#545e09' => 'Juniper', '#515e09' => 'Moss', '#4e5f0a' => 'Camouflage', '#4b5f0a' => 'Lincoln Green', '#48600a' => 'Lustrian Undergrowth', '#45600a' => 'Green Leaf', '#41610a' => 'Fern Green', '#3d620a' => 'Forest Empress', '#3a620a' => 'Forestial Escapade', '#35630a' => 'Espinaca', '#31630a' => 'Olive Green', '#2c640a' => 'Grass Green', '#26640a' => 'Navy Green', '#20650a' => 'Forest', '#18650a' => 'Overgrown Temple', '#0a660a' => 'Leafy Lush', '#0a631a' => 'Pearl Green', '#0a6023' => 'Cadmium Green', '#0a5d2a' => 'Woodland Wonder', '#0a5a31' => 'Ficus Elastica', '#0a5736' => 'Spruce', '#0a533b' => 'Tropical Forest', '#0a5040' => 'Raspberry Leaf Green', '#0a4c44' => 'Jolie Pixie', '#0a4848' => 'Peacock', '#0a444c' => 'Midnight Green', '#0a4050' => 'Dark Teal', '#0a3b53' => 'Duskwood', '#0a3657' => 'Beyond The Stars', '#0a315a' => 'Marine', '#0a2a5d' => 'Ambassador Blue', '#0a2360' => 'Black Sea Night', '#0a1a63' => 'Deep Sapphire', '#0a0a66' => 'Darkblue', '#140a65' => 'Arapawa', '#1a0a64' => 'Underground Stream', '#1f0a62' => 'Azul Senales', '#230a61' => 'Signal Blue', '#270a60' => 'Ocean Abyss', '#2b0a5f' => 'Paua', '#2e0a5e' => 'Midnight Blue', '#310a5c' => 'Bleu Nuit', '#340a5b' => 'Indigo', '#3e0a56' => 'Ripe Plum', '#470a50' => 'Clairvoyant', '#4f0a4b' => 'Tyrian Purple', '#560a44' => 'Cosmic Explorer', '#5c0b3d' => 'Plum', '#630b35' => 'Mulberry', '#680b2c' => 'Boysenberry', '#6c0b24' => 'Rouge Bordeaux');
                $getcss = file_get_contents(get_stylesheet_directory() . '/custom/css-compiled/snowpage.css');
                preg_match('/(?<=\.bg-minya {\n  background-color: ).*(?=;)/', $getcss, $getminya);
                preg_match('/(?<=\.bg-tatya {\n  background-color: ).*(?=;)/', $getcss, $gettatya);
                preg_match('/(?<=\.bg-nelya {\n  background-color: ).*(?=;)/', $getcss, $getnelya);
                preg_match('/(?<=\.bg-cantea {\n  background-color: ).*(?=;)/', $getcss, $getcantea);
                preg_match('/(?<=\.bg-lemenya {\n  background-color: ).*(?=;)/', $getcss, $getlemenya);
                $minyabase = $getminya[0];
                $updateminya = "    - '" . $getminya[0] . "'\n";
                $updateminyatwo = "'" . $getminya[0] . "'";
                $updatetatya = "    - '" . $gettatya[0] . "'\n";
                $updatenelya = "    - '" . $getnelya[0] . "'\n";
                $updatecantea = "    - '" . $getcantea[0] . "'\n";
                $updatelemenya = "    - '" . $getlemenya[0] . "'\n";
                $getyaml = file_get_contents(get_template_directory() . '/gantry/presets.yaml');
                $getdef = file_get_contents(get_stylesheet_directory() . '/custom/config/default/styles.yaml');
                $setdef = preg_replace("/(?<=color: ).*/", $updateminyatwo, $getdef);
                $setyaml = preg_replace('/(?<=colors:\n).*\n.*\n.*\n.*\n.*\n.*\n/', $updateminya . $updateminya . $updatetatya . $updatenelya . $updatecantea . $updatelemenya, $getyaml);
                $setyaml = preg_replace('/(?<=color: ).*/', $updateminyatwo, $setyaml);
                $setyaml = preg_replace('/(?<=description: ).*/', $colorname[$minyabase], $setyaml);
                $setyaml = preg_replace('/(?<=\/images\/).*(?=\.p)/', substr($minyabase, -6), $setyaml);
                file_put_contents(get_stylesheet_directory() . '/custom/config/default/styles.yaml', $setdef);
                file_put_contents(get_template_directory() . '/custom/config/default/styles.yaml', $setdef);
                file_put_contents(get_template_directory() . '/gantry/presets.yaml', $setyaml);
                update_option('graupel_color', $minyabase);
            }
        }
 
Exception message: Undefined array key 0
                    break;
            }
 
            return;
        }
 
        /** 
        * @param hex $indexcolor
        */
        public function checkColor( $indexcolor ) {
            $colorlist = get_option('graupel_color');
            if ($colorlist != $indexcolor) {
                $colorname = array('#730b0b' => 'Coffee Brick', '#72160b' => 'Rouge Bourgogne', '#711d0b' => 'Berry', '#70230b' => 'Cinnamon', '#6f280b' => 'Cold Press Coffee', '#6e2d0a' => 'Seal Brown', '#6d310a' => 'Caramel', '#6c340a' => 'Sepia', '#6b380a' => 'Philippine Bronze', '#6a3b0a' => 'Colorado', '#69400a' => 'Violin Brown', '#67440a' => 'Saddlebrown', '#66480a' => 'Terre Sienne', '#644b0a' => 'Very Coffee', '#624f09' => 'Ayahuasca Vine', '#615209' => 'Olive Brown', '#5f5609' => 'Antique Bronze', '#5e5909' => 'Saratoga', '#5c5c09' => 'Brussels Sprout', '#595d09' => 'Douro', '#575d09' => 'Forestial Outpost', '#545e09' => 'Juniper', '#515e09' => 'Moss', '#4e5f0a' => 'Camouflage', '#4b5f0a' => 'Lincoln Green', '#48600a' => 'Lustrian Undergrowth', '#45600a' => 'Green Leaf', '#41610a' => 'Fern Green', '#3d620a' => 'Forest Empress', '#3a620a' => 'Forestial Escapade', '#35630a' => 'Espinaca', '#31630a' => 'Olive Green', '#2c640a' => 'Grass Green', '#26640a' => 'Navy Green', '#20650a' => 'Forest', '#18650a' => 'Overgrown Temple', '#0a660a' => 'Leafy Lush', '#0a631a' => 'Pearl Green', '#0a6023' => 'Cadmium Green', '#0a5d2a' => 'Woodland Wonder', '#0a5a31' => 'Ficus Elastica', '#0a5736' => 'Spruce', '#0a533b' => 'Tropical Forest', '#0a5040' => 'Raspberry Leaf Green', '#0a4c44' => 'Jolie Pixie', '#0a4848' => 'Peacock', '#0a444c' => 'Midnight Green', '#0a4050' => 'Dark Teal', '#0a3b53' => 'Duskwood', '#0a3657' => 'Beyond The Stars', '#0a315a' => 'Marine', '#0a2a5d' => 'Ambassador Blue', '#0a2360' => 'Black Sea Night', '#0a1a63' => 'Deep Sapphire', '#0a0a66' => 'Darkblue', '#140a65' => 'Arapawa', '#1a0a64' => 'Underground Stream', '#1f0a62' => 'Azul Senales', '#230a61' => 'Signal Blue', '#270a60' => 'Ocean Abyss', '#2b0a5f' => 'Paua', '#2e0a5e' => 'Midnight Blue', '#310a5c' => 'Bleu Nuit', '#340a5b' => 'Indigo', '#3e0a56' => 'Ripe Plum', '#470a50' => 'Clairvoyant', '#4f0a4b' => 'Tyrian Purple', '#560a44' => 'Cosmic Explorer', '#5c0b3d' => 'Plum', '#630b35' => 'Mulberry', '#680b2c' => 'Boysenberry', '#6c0b24' => 'Rouge Bordeaux');
                $getcss = file_get_contents(get_stylesheet_directory() . '/custom/css-compiled/snowpage.css');
                preg_match('/(?<=\.bg-minya {\n  background-color: ).*(?=;)/', $getcss, $getminya);
                preg_match('/(?<=\.bg-tatya {\n  background-color: ).*(?=;)/', $getcss, $gettatya);
                preg_match('/(?<=\.bg-nelya {\n  background-color: ).*(?=;)/', $getcss, $getnelya);
                preg_match('/(?<=\.bg-cantea {\n  background-color: ).*(?=;)/', $getcss, $getcantea);
                preg_match('/(?<=\.bg-lemenya {\n  background-color: ).*(?=;)/', $getcss, $getlemenya);
                $minyabase = $getminya[0];
                $updateminya = "    - '" . $getminya[0] . "'\n";
                $updateminyatwo = "'" . $getminya[0] . "'";
                $updatetatya = "    - '" . $gettatya[0] . "'\n";
                $updatenelya = "    - '" . $getnelya[0] . "'\n";
                $updatecantea = "    - '" . $getcantea[0] . "'\n";
                $updatelemenya = "    - '" . $getlemenya[0] . "'\n";
                $getyaml = file_get_contents(get_template_directory() . '/gantry/presets.yaml');
                $getdef = file_get_contents(get_stylesheet_directory() . '/custom/config/default/styles.yaml');
                $setdef = preg_replace("/(?<=color: ).*/", $updateminyatwo, $getdef);
                $setyaml = preg_replace('/(?<=colors:\n).*\n.*\n.*\n.*\n.*\n.*\n/', $updateminya . $updateminya . $updatetatya . $updatenelya . $updatecantea . $updatelemenya, $getyaml);
                $setyaml = preg_replace('/(?<=color: ).*/', $updateminyatwo, $setyaml);
                $setyaml = preg_replace('/(?<=description: ).*/', $colorname[$minyabase], $setyaml);
                $setyaml = preg_replace('/(?<=\/images\/).*(?=\.p)/', substr($minyabase, -6), $setyaml);
                file_put_contents(get_stylesheet_directory() . '/custom/config/default/styles.yaml', $setdef);
                file_put_contents(get_template_directory() . '/custom/config/default/styles.yaml', $setdef);
                file_put_contents(get_template_directory() . '/gantry/presets.yaml', $setyaml);
                update_option('graupel_color', $minyabase);
            }
        }
 
        $this->blocks = [
            'content' => [$this, 'block_content'],
        ];
    }
 
    protected function doGetParent(array $context)
    {
        // line 1
        return "partials/page.html.twig";
    }
 
    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 2
        $context["twigTemplate"] = "index.html.twig";
        // line 3
        $context["scope"] = "blog";
        // line 4
        $context["melt"] = $this->extensions['Gantry\Component\Twig\TwigExtension']->checkColor(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["gantry"] ?? null), "config", [], "any", false, false, false, 4), "styles", [], "any", false, false, false, 4), "inital", [], "any", false, false, false, 4), "color", [], "any", false, false, false, 4));
        // line 1
        $this->parent = $this->loadTemplate("partials/page.html.twig", "index.html.twig", 1);
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }
 
    // line 6
    public function block_content($context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 7
        echo "
    <div class=\"platform-content\">
        <div class=\"blog\">
 
            ";
        // line 12
        echo "            ";
        if ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["gantry"] ?? null), "config", [], "any", false, false, false, 12), "get", [0 => (("content." . ($context["scope"] ?? null)) . ".heading.enabled"), 1 => "0"], "method", false, false, false, 12) &&  !twig_test_empty(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["gantry"] ?? null), "config", [], "any", false, false, false, 12), "get", [0 => (("content." . ($context["scope"] ?? null)) . ".heading.text")], "method", false, false, false, 12)))) {
            // line 13
            echo "                <header class=\"page-header\">
        } else {
            ob_start(function () { return ''; });
        }
        try {
            $this->display($context);
        } catch (\Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = [])
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for \Twig\Error\LoaderError exceptions
            // see \Twig\Error\LoaderError
            if (-1 === $e->getTemplateLine()) {
                $e->guess();
            }
 
            throw $e;
        } catch (\Exception $e) {
            $e = new RuntimeError(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
            $e->guess();
 
            throw $e;
        }
    }
 
    {
        return $this;
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = [])
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        if ($this->env->isDebug()) {
            ob_start();
        } else {
            ob_start(function () { return ''; });
        }
        try {
            $this->display($context);
        } catch (\Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = [])
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        if ($this->env->isDebug()) {
            ob_start();
        } else {
            ob_start(function () { return ''; });
        }
        try {
            $this->display($context);
        } catch (\Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = [])
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
     * directly (use Twig\Environment::load() instead).
     *
     * @internal
     */
    public function __construct(Environment $env, Template $template)
    {
        $this->env = $env;
        $this->template = $template;
    }
 
    /**
     * Renders the template.
     *
     * @param array $context An array of parameters to pass to the template
     */
    public function render(array $context = []): string
    {
        // using func_get_args() allows to not expose the blocks argument
        // as it should only be used by internal code
        return $this->template->render($context, \func_get_args()[1] ?? []);
    }
 
    /**
     * Displays the template.
     *
     * @param array $context An array of parameters to pass to the template
     */
    public function display(array $context = [])
    {
        // using func_get_args() allows to not expose the blocks argument
        // as it should only be used by internal code
        $this->template->display($context, \func_get_args()[1] ?? []);
    }
 
    /**
     * Checks if a block is defined.
     *
     * @param string $name    The block name
     * @param array  $context An array of parameters to pass to the template
     */
 
        $key = null;
        $output = false;
        if ( false !== $expires ) {
            ksort($data);
            $key = md5($file.json_encode($data));
            $output = $this->get_cache($key, self::CACHEGROUP, $cache_mode);
        }
 
        if ( false === $output || null === $output ) {
            $twig = $this->get_twig();
            if ( strlen($file) ) {
                $loader = $this->get_loader();
                $result = $loader->getCacheKey($file);
                do_action('timber_loader_render_file', $result);
            }
            $data = apply_filters('timber_loader_render_data', $data);
            $data = apply_filters('timber/loader/render_data', $data, $file);
            $template = $twig->load($file);
            $output = $template->render($data);
        }
 
        if ( false !== $output && false !== $expires && null !== $key ) {
            $this->delete_cache();
            $this->set_cache($key, $output, self::CACHEGROUP, $expires, $cache_mode);
        }
        $output = apply_filters('timber_output', $output);
        return apply_filters('timber/output', $output, $data, $file);
    }
 
    protected function delete_cache() {
        Cleaner::delete_transients();
    }
 
    /**
     * Get first existing template.
     *
     * @param array|string $templates  Name(s) of the Twig template(s) to choose from.
     * @return string|bool             Name of chosen template, otherwise false.
     */
        if ( $via_render ) {
            $file = apply_filters('timber_render_file', $file);
        } else {
            $file = apply_filters('timber_compile_file', $file);
        }
 
        $output = false;
 
        if ($file !== false) {
            if ( is_null($data) ) {
                $data = array();
            }
 
            if ( $via_render ) {
                $data = apply_filters('timber_render_data', $data);
            } else {
                $data = apply_filters('timber_compile_data', $data);
            }
 
            $output = $loader->render($file, $data, $expires, $cache_mode);
        } else {
            if ( is_array($filenames) ) {
                $filenames = implode(", ", $filenames);
            }
            Helper::error_log( 'Error loading your template files: '.$filenames.'. Make sure one of these files exists.' );
        }
 
        do_action('timber_compile_done');
        return $output;
    }
 
    /**
     * Compile a string.
     *
     * @api
     * @example
     * ```php
     * $data = array(
     *     'username' => 'Jane Doe',
     * );
        $twig = $dummy_loader->get_twig();
        $template = $twig->createTemplate($string);
        return $template->render($data);
    }
 
    /**
     * Fetch function.
     *
     * @api
     * @param array|string $filenames  Name of the Twig file to render. If this is an array of files, Timber will
     *                                 render the first file that exists.
     * @param array        $data       Optional. An array of data to use in Twig template.
     * @param bool|int     $expires    Optional. In seconds. Use false to disable cache altogether. When passed an
     *                                 array, the first value is used for non-logged in visitors, the second for users.
     *                                 Default false.
     * @param string       $cache_mode Optional. Any of the cache mode constants defined in TimberLoader.
     * @return bool|string The returned output.
     */
    public static function fetch( $filenames, $data = array(), $expires = false, $cache_mode = Loader::CACHE_USE_DEFAULT ) {
        $output = self::compile($filenames, $data, $expires, $cache_mode, true);
        $output = apply_filters('timber_compile_result', $output);
        return $output;
    }
 
    /**
     * Render function.
     *
     * Passes data to a Twig file and echoes the output.
     *
     * @api
     * @example
     * ```php
     * $context = Timber::context();
     *
     * Timber::render( 'index.twig', $context );
     * ```
     * @param array|string $filenames  Name of the Twig file to render. If this is an array of files, Timber will
     *                                 render the first file that exists.
     * @param array        $data       Optional. An array of data to use in Twig template.
     * @param bool|int     $expires    Optional. In seconds. Use false to disable cache altogether. When passed an
     * Passes data to a Twig file and echoes the output.
     *
     * @api
     * @example
     * ```php
     * $context = Timber::context();
     *
     * Timber::render( 'index.twig', $context );
     * ```
     * @param array|string $filenames  Name of the Twig file to render. If this is an array of files, Timber will
     *                                 render the first file that exists.
     * @param array        $data       Optional. An array of data to use in Twig template.
     * @param bool|int     $expires    Optional. In seconds. Use false to disable cache altogether. When passed an
     *                                 array, the first value is used for non-logged in visitors, the second for users.
     *                                 Default false.
     * @param string       $cache_mode Optional. Any of the cache mode constants defined in TimberLoader.
     * @return bool|string The echoed output.
     */
    public static function render( $filenames, $data = array(), $expires = false, $cache_mode = Loader::CACHE_USE_DEFAULT ) {
        $output = self::fetch($filenames, $data, $expires, $cache_mode);
        echo $output;
        return $output;
    }
 
    /**
     * Render a string with Twig variables.
     *
     * @api
     * @example
     * ```php
     * $data = array(
     *     'username' => 'Jane Doe',
     * );
     *
     * Timber::render_string( 'Hi {{ username }}, I’m a string with a custom Twig variable', $data );
     * ```
     * @param string $string A string with Twig variables.
     * @param array  $data   An array of data to use in Twig template.
     * @return bool|string
     */
            "mx"
        ),
    "switcher_text_color" => "#666",
    "switcher_arrow_color" => "#666",
    "switcher_border_color" => "#ccc",
    "switcher_background_color" => "#fff",
    "switcher_background_shadow_color" => "#efefef",
    "switcher_background_hover_color" => "#fff",
    "dropdown_text_color" => "#000",
    "dropdown_hover_color" => "#fff",
    "dropdown_background_color" => "#eee",
    "float_switcher_open_direction" => "top",
    "switcher_open_direction" => "top",
    "language_codes" => "en,es,zh-CN,vi,ar,fr,ko,uk,de,ja,sv,it,cy,ru,af,sq,am,hy,az,eu,be,bn,bs,bg,ca,ceb,ny,zh-TW,co,hr,cs,da,nl,eo,et,tl,fi,fy,gl,ka,el,gu,ht,ha,haw,iw,hi,hmn,hu,is,ig,id,ga,jw,kn,kk,km,ku,ky,lo,la,lv,lt,lb,mk,mg,ms,ml,mt,mi,mr,mn,my,ne,no,ps,fa,pl,pt,pa,ro,sm,gd,sr,st,sn,sd,si,sk,sl,so,su,sw,tg,ta,te,th,tr,ur,uz,xh,yi,yo,zu",
    "language_codes2" => "af,sq,am,ar,hy,az,eu,be,bn,bs,bg,ca,ceb,ny,zh-CN,zh-TW,co,hr,cs,da,nl,en,eo,et,tl,fi,fr,fy,gl,ka,de,el,gu,ht,ha,haw,iw,hi,hmn,hu,is,ig,id,ga,it,ja,jw,kn,kk,km,ko,ku,ky,lo,la,lv,lt,lb,mk,mg,ms,ml,mt,mi,mr,mn,my,ne,no,ps,fa,pl,pt,pa,ro,ru,sm,gd,sr,st,sn,sd,si,sk,sl,so,es,su,sw,sv,tg,ta,te,th,tr,uk,ur,uz,vi,cy,xh,yi,yo,zu"
);
 
update_option( 'GTranslate', $gtrans );
 
Timber::render($templates, $context);
 
     */
    $template   = apply_filters( 'template_include', $template );
    $is_stringy = is_string( $template ) || ( is_object( $template ) && method_exists( $template, '__toString' ) );
    $template   = $is_stringy ? realpath( (string) $template ) : null;
    if (
        is_string( $template ) &&
        ( str_ends_with( $template, '.php' ) || str_ends_with( $template, '.html' ) ) &&
        is_file( $template ) &&
        is_readable( $template )
    ) {
        /**
         * Fires immediately before including the template.
         *
         * @since 6.9.0
         *
         * @param string $template The path of the template about to be included.
         */
        do_action( 'wp_before_include_template', $template );
 
        include $template;
    } elseif ( current_user_can( 'switch_themes' ) ) {
        $theme = wp_get_theme();
        if ( $theme->errors() ) {
            wp_die( $theme->errors() );
        }
    }
    return;
}
 
<?php
/**
 * Loads the WordPress environment and template.
 *
 * @package WordPress
 */
 
if ( ! isset( $wp_did_header ) ) {
 
    $wp_did_header = true;
 
    // Load the WordPress library.
    require_once __DIR__ . '/wp-load.php';
 
    // Set up the WordPress query.
    wp();
 
    // Load the theme template.
    require_once ABSPATH . WPINC . '/template-loader.php';
 
}
 
<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */
 
/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define( 'WP_USE_THEMES', true );
 
/** Loads the WordPress Environment and Template */
require __DIR__ . '/wp-blog-header.php';
 

Environment & details:

Key Value
p 0
empty
empty
empty
empty
Key Value
SERVER_SOFTWARE Apache
REQUEST_URI /?p=0
USER ac0b36b7
HOME /home/ac0b36b7
SCRIPT_NAME /index.php
QUERY_STRING p=0
REQUEST_METHOD GET
SERVER_PROTOCOL HTTP/1.1
GATEWAY_INTERFACE CGI/1.1
REMOTE_PORT 30437
SCRIPT_FILENAME /home/ac0b36b7/bb6aeb0386.nxcli.io/html/index.php
SERVER_ADMIN [email protected]
CONTEXT_DOCUMENT_ROOT /home/ac0b36b7/bb6aeb0386.nxcli.io/html
CONTEXT_PREFIX
REQUEST_SCHEME http
DOCUMENT_ROOT /home/ac0b36b7/bb6aeb0386.nxcli.io/html
REMOTE_ADDR 216.73.217.9
SERVER_PORT 80
SERVER_ADDR 10.64.162.21
SERVER_NAME ashvillelibrary.com
SERVER_SIGNATURE
PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin
HTTP_CF_VISITOR {\"scheme\":\"https\"}
HTTP_CF_IPCOUNTRY US
HTTP_CF_CONNECTING_IP 216.73.217.9
HTTP_CDN_LOOP cloudflare; loops=1
HTTP_CF_RAY a480ffa468403524-CMH
HTTP_ACCEPT */*
HTTP_USER_AGENT Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; [email protected])
HTTP_ACCEPT_ENCODING gzip, br
HTTP_CONNECTION close
HTTP_X_REQUEST_ID b30a9f1cb828bfebed33f60f5a42ebe6
HTTP_X_ORIGINAL_REQUEST /?p=0
HTTP_X_FORWARDED_SERVER ashvillelibrary.com
HTTP_X_FORWARDED_HOST ashvillelibrary.com
HTTP_X_CONNECTING_IP 162.159.114.99
HTTP_X_REAL_IP 216.73.217.9
HTTP_HOST ashvillelibrary.com
HTTP_X_FORWARDED_PROTO https
SCRIPT_URI http://ashvillelibrary.com/
SCRIPT_URL /
HTTPS on
QS_ConnectionId 17915867962699801531659
QS_AllConn 8
QS_SrvConn 8
GEOIP_ASN 16509
GEOIP_ASORG Amazon.com, Inc.
CITY_DB_NETWORK 216.73.216.0/22
GEOIP_COUNTRY_CODE US
GEOIP_LATITUDE 39.95870
GEOIP_LONGITUDE -82.99870
GEOIP_CITY_NAME Columbus
GEOIP_COUNTRY_NAME United States
MMDB_INFO result found
MMDB_ADDR 216.73.217.9
UNIQUE_ID aslx7HWN3jfyg1DbuiLFmQAAAHM
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1791586796.275
REQUEST_TIME 1791586796
empty
0. Whoops\Handler\PrettyPageHandler