Twig_Error_Runtime
An exception has been thrown during the rendering of a template ("Unable to write in the cache directory (/home/online78/public_html/cache/gantry5/g5_helium/twig/8b)."). Twig_Error_Runtime thrown with message "An exception has been thrown during the rendering of a template ("Unable to write in the cache directory (/home/online78/public_html/cache/gantry5/g5_helium/twig/8b).")." Stacktrace: #47 Twig_Error_Runtime in /home/online78/public_html/media/gantry5/engines/nucleus/particles/custom.html.twig:4 #46 RuntimeException in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Twig/TwigCacheFilesystem.php:62 #45 Gantry\Component\Twig\TwigCacheFilesystem:write in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Environment.php:457 #44 Twig_Environment:loadTemplate in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Environment.php:521 #43 Twig_Environment:createTemplate in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/AbstractTheme.php:175 #42 Gantry\Component\Theme\AbstractTheme:compile in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:677 #41 Twig_Template:getAttribute in /home/online78/public_html/cache/gantry5/g5_helium/twig/cb/cb9fc463691324d533276936c1351962b243d64e197c5b1df9164c54f4daaa38.php:32 #40 __TwigTemplate_47426fba76f1f42b1ed0db70207904e96a785da711af3505f6704b7c8974561d:block_particle in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:215 #39 Twig_Template:displayBlock in /home/online78/public_html/cache/gantry5/g5_helium/twig/00/00f8e99011c5c14ff7560b12951a66a738bbfda08ca8507518d72fcd983004d9.php:62 #38 __TwigTemplate_a8e583fec2cc86072534a4597c9c8fa642272ae41c41c8253fafc09948d76134:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #37 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #36 Twig_Template:display in /home/online78/public_html/cache/gantry5/g5_helium/twig/cb/cb9fc463691324d533276936c1351962b243d64e197c5b1df9164c54f4daaa38.php:24 #35 __TwigTemplate_47426fba76f1f42b1ed0db70207904e96a785da711af3505f6704b7c8974561d:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #34 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #33 Twig_Template:display in /home/online78/public_html/cache/gantry5/g5_helium/twig/f7/f7c4221b05c89b44c6f10d02f38868a39d571b78a82ebc5ab00f643f1507bb3e.php:60 #32 __TwigTemplate_fd5ee0842d7d204b328fb7f1ea4e1b8cfa83d0d2f6b78bbe6a452bbae4d2c852:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #31 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #30 Twig_Template:display in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:411 #29 Twig_Template:render in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Environment.php:363 #28 Twig_Environment:render in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/AbstractTheme.php:162 #27 Gantry\Component\Theme\AbstractTheme:render in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:766 #26 Gantry\Framework\Theme:getContent in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:666 #25 Gantry\Framework\Theme:renderContent in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:593 #24 Gantry\Framework\Theme:prepareLayout in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:579 #23 Gantry\Framework\Theme:prepareLayout in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:579 #22 Gantry\Framework\Theme:prepareLayout in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:579 #21 Gantry\Framework\Theme:prepareLayout in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/ThemeTrait.php:422 #20 Gantry\Framework\Theme:segments in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:675 #19 Twig_Template:getAttribute in /home/online78/public_html/cache/gantry5/g5_helium/twig/fe/fedbf6eb87186b4acf72b1f6b5e046f4da0020fb8d163d18bbb2fbe72e3e6855.php:36 #18 __TwigTemplate_9c4ef402e28d3f7fe73d62be9db61846b6af6e91413b84cbb27ea6c2f6ebf4cb:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #17 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #16 Twig_Template:display in /home/online78/public_html/cache/gantry5/g5_helium/twig/4a/4a9cf6d3e9b573f34f4b7aa17c1d1a564ea6a3ddb7c43d9fd716e7d4568ae16c.php:24 #15 __TwigTemplate_48eab42404479ff53ea1d0f527383a04e44dc7db33caf3c55393f0a4050aa45e:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #14 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #13 Twig_Template:display in /home/online78/public_html/cache/gantry5/g5_helium/twig/6f/6fafeacbc5eb1b40fbb1cdad66bd4c63b37b9234b465f2e38c550ae245f07395.php:24 #12 __TwigTemplate_526d520fd769a3ed359caa44911c41b3423a4bfac34ed9e5dbec576bb32ba5bd:doDisplay in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:432 #11 Twig_Template:displayWithErrorHandling in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:403 #10 Twig_Template:display in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Template.php:411 #9 Twig_Template:render in /home/online78/public_html/libraries/gantry5/vendor/twig/twig/lib/Twig/Environment.php:363 #8 Twig_Environment:render in /home/online78/public_html/libraries/gantry5/classes/Gantry/Component/Theme/AbstractTheme.php:162 #7 Gantry\Component\Theme\AbstractTheme:render in /home/online78/public_html/templates/g5_helium/index.php:23 #6 require in /home/online78/public_html/libraries/joomla/document/html.php:653 #5 JDocumentHtml:_loadTemplate in /home/online78/public_html/libraries/joomla/document/html.php:715 #4 JDocumentHtml:_fetchTemplate in /home/online78/public_html/libraries/joomla/document/html.php:530 #3 JDocumentHtml:parse in /home/online78/public_html/libraries/cms/application/cms.php:1102 #2 JApplicationCms:render in /home/online78/public_html/libraries/cms/application/site.php:777 #1 JApplicationSite:render in /home/online78/public_html/libraries/cms/application/cms.php:271 #0 JApplicationCms:execute in /home/online78/public_html/index.php:49
Stack frames (48)
47
Twig_Error_Runtime
/
home
/
online78
/
public_html
/
media
/
gantry5
/
engines
/
nucleus
/
particles
/
custom.html.twig
4
46
RuntimeException
/
classes
/
Gantry
/
Component
/
Twig
/
TwigCacheFilesystem.php
62
45
Gantry
\
Component
\
Twig
\
TwigCacheFilesystem
write
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Environment.php
457
44
Twig_Environment
loadTemplate
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Environment.php
521
43
Twig_Environment
createTemplate
/
classes
/
Gantry
/
Component
/
Theme
/
AbstractTheme.php
175
42
Gantry
\
Component
\
Theme
\
AbstractTheme
compile
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
677
41
Twig_Template
getAttribute
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
cb
/
cb9fc463691324d533276936c1351962b243d64e197c5b1df9164c54f4daaa38.php
32
40
__TwigTemplate_47426fba76f1f42b1ed0db70207904e96a785da711af3505f6704b7c8974561d
block_particle
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
215
39
Twig_Template
displayBlock
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
00
/
00f8e99011c5c14ff7560b12951a66a738bbfda08ca8507518d72fcd983004d9.php
62
38
__TwigTemplate_a8e583fec2cc86072534a4597c9c8fa642272ae41c41c8253fafc09948d76134
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
37
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
36
Twig_Template
display
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
cb
/
cb9fc463691324d533276936c1351962b243d64e197c5b1df9164c54f4daaa38.php
24
35
__TwigTemplate_47426fba76f1f42b1ed0db70207904e96a785da711af3505f6704b7c8974561d
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
34
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
33
Twig_Template
display
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
f7
/
f7c4221b05c89b44c6f10d02f38868a39d571b78a82ebc5ab00f643f1507bb3e.php
60
32
__TwigTemplate_fd5ee0842d7d204b328fb7f1ea4e1b8cfa83d0d2f6b78bbe6a452bbae4d2c852
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
31
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
30
Twig_Template
display
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
411
29
Twig_Template
render
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Environment.php
363
28
Twig_Environment
render
/
classes
/
Gantry
/
Component
/
Theme
/
AbstractTheme.php
162
27
Gantry
\
Component
\
Theme
\
AbstractTheme
render
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
766
26
Gantry
\
Framework
\
Theme
getContent
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
666
25
Gantry
\
Framework
\
Theme
renderContent
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
593
24
Gantry
\
Framework
\
Theme
prepareLayout
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
579
23
Gantry
\
Framework
\
Theme
prepareLayout
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
579
22
Gantry
\
Framework
\
Theme
prepareLayout
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
579
21
Gantry
\
Framework
\
Theme
prepareLayout
/
classes
/
Gantry
/
Component
/
Theme
/
ThemeTrait.php
422
20
Gantry
\
Framework
\
Theme
segments
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
675
19
Twig_Template
getAttribute
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
fe
/
fedbf6eb87186b4acf72b1f6b5e046f4da0020fb8d163d18bbb2fbe72e3e6855.php
36
18
__TwigTemplate_9c4ef402e28d3f7fe73d62be9db61846b6af6e91413b84cbb27ea6c2f6ebf4cb
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
17
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
16
Twig_Template
display
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
4a
/
4a9cf6d3e9b573f34f4b7aa17c1d1a564ea6a3ddb7c43d9fd716e7d4568ae16c.php
24
15
__TwigTemplate_48eab42404479ff53ea1d0f527383a04e44dc7db33caf3c55393f0a4050aa45e
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
14
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
13
Twig_Template
display
/
home
/
online78
/
public_html
/
cache
/
gantry5
/
g5_helium
/
twig
/
6f
/
6fafeacbc5eb1b40fbb1cdad66bd4c63b37b9234b465f2e38c550ae245f07395.php
24
12
__TwigTemplate_526d520fd769a3ed359caa44911c41b3423a4bfac34ed9e5dbec576bb32ba5bd
doDisplay
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
432
11
Twig_Template
displayWithErrorHandling
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
403
10
Twig_Template
display
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Template.php
411
9
Twig_Template
render
/
vendor
/
twig
/
twig
/
lib
/
Twig
/
Environment.php
363
8
Twig_Environment
render
/
classes
/
Gantry
/
Component
/
Theme
/
AbstractTheme.php
162
7
Gantry
\
Component
\
Theme
\
AbstractTheme
render
/
home
/
online78
/
public_html
/
templates
/
g5_helium
/
index.php
23
6
require
/
home
/
online78
/
public_html
/
libraries
/
joomla
/
document
/
html.php
653
5
JDocumentHtml
_loadTemplate
/
home
/
online78
/
public_html
/
libraries
/
joomla
/
document
/
html.php
715
4
JDocumentHtml
_fetchTemplate
/
home
/
online78
/
public_html
/
libraries
/
joomla
/
document
/
html.php
530
3
JDocumentHtml
parse
/
home
/
online78
/
public_html
/
libraries
/
cms
/
application
/
cms.php
1102
2
JApplicationCms
render
/
home
/
online78
/
public_html
/
libraries
/
cms
/
application
/
site.php
777
1
JApplicationSite
render
/
home
/
online78
/
public_html
/
libraries
/
cms
/
application
/
cms.php
271
0
JApplicationCms
execute
/
home
/
online78
/
public_html
/
index.php
49
{% extends '@nucleus/partials/particle.html.twig' %}
 
{% block particle %}
    {% set html = particle.twig ? gantry.theme.compile(particle.html) : particle.html %}
    {{ (particle.filter ? gantry.platform.filter(html) : html)|html|raw }}
{% endblock %}
 
    }
    /**
     * {@inheritdoc}
     */
    public function load($key)
    {
        @include_once $key;
    }
    /**
     * {@inheritdoc}
     */
    public function write($key, $content)
    {
        $dir = dirname($key);
        if (!is_dir($dir)) {
            if (false === @mkdir($dir, 0777, true) && !is_dir($dir)) {
                throw new \RuntimeException(sprintf('Unable to create the cache directory (%s).', $dir));
            }
        } elseif (!is_writable($dir)) {
            throw new \RuntimeException(sprintf('Unable to write in the cache directory (%s).', $dir));
        }
        $tmpFile = tempnam($dir, basename($key));
        if (false !== @file_put_contents($tmpFile, $content) && @rename($tmpFile, $key)) {
            @chmod($key, 0666 & ~umask());
            if (self::FORCE_BYTECODE_INVALIDATION == ($this->options & self::FORCE_BYTECODE_INVALIDATION)) {
                // Compile cached file into bytecode cache
                if (function_exists('opcache_invalidate')) {
                    // Silence error in case if `opcache.restrict_api` directive is set.
                    @opcache_invalidate($key, true);
                } elseif (function_exists('apc_compile_file')) {
                    @apc_compile_file($key);
                }
            }
            return;
        }
        throw new \RuntimeException(sprintf('Failed to write cache file "%s".', $key));
    }
    /**
     * {@inheritdoc}
     */
Exception message: Unable to write in the cache directory (/home/online78/public_html/cache/gantry5/g5_helium/twig/8b).
            }
 
            if (!$this->isAutoReload() || $this->isTemplateFresh($name, $this->cache->getTimestamp($key))) {
                $this->cache->load($key);
            }
 
            if (!class_exists($cls, false)) {
                $loader = $this->getLoader();
                if (!$loader instanceof Twig_SourceContextLoaderInterface) {
                    $source = new Twig_Source($loader->getSource($name), $name);
                } else {
                    $source = $loader->getSourceContext($name);
                }
 
                $content = $this->compileSource($source);
 
                if ($this->bcWriteCacheFile) {
                    $this->writeCacheFile($key, $content);
                } else {
                    $this->cache->write($key, $content);
                    $this->cache->load($key);
                }
 
                if (!class_exists($mainCls, false)) {
                    /* Last line of defense if either $this->bcWriteCacheFile was used,
                     * $this->cache is implemented as a no-op or we have a race condition
                     * where the cache was cleared between the above calls to write to and load from
                     * the cache.
                     */
                    eval('?>'.$content);
                }
            }
 
            if (!class_exists($cls, false)) {
                throw new Twig_Error_Runtime(sprintf('Failed to load Twig template "%s", index "%s": cache is corrupted.', $name, $index), -1, $source);
            }
        }
 
        if (!$this->runtimeInitialized) {
            $this->initRuntime();
     *
     * @param string $template The template name
     *
     * @return Twig_Template A template instance representing the given template name
     *
     * @throws Twig_Error_Loader When the template cannot be found
     * @throws Twig_Error_Syntax When an error occurred during compilation
     */
    public function createTemplate($template)
    {
        $name = sprintf('__string_template__%s', hash('sha256', $template, false));
 
        $loader = new Twig_Loader_Chain(array(
            new Twig_Loader_Array(array($name => $template)),
            $current = $this->getLoader(),
        ));
 
        $this->setLoader($loader);
        try {
            $template = $this->loadTemplate($name);
        } catch (Exception $e) {
            $this->setLoader($current);
 
            throw $e;
        } catch (Throwable $e) {
            $this->setLoader($current);
 
            throw $e;
        }
        $this->setLoader($current);
 
        return $template;
    }
 
    /**
     * Returns true if the template is still fresh.
     *
     * Besides checking the loader for freshness information,
     * this method also checks if the enabled extensions have
     * not changed.
     */
    public function render($file, array $context = [])
    {
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $this->renderer()->render($file, $context);
    }
 
    /**
     * Compile and render twig string.
     *
     * @param string $string
     * @param array $context
     * @return string
     */
    public function compile($string, array $context = [])
    {
        $renderer = $this->renderer();
        $template = $renderer->createTemplate($string);
 
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $template->render($context);
    }
 
    /**
     * Initialize theme.
     */
    protected function init()
    {
        $gantry = static::gantry();
        $gantry['streams']->register();
 
        // Only add error service if development or debug mode has been enabled or user is admin.
        if (!$gantry['global']->get('production', 0) || $gantry->debug() || $gantry->admin()) {
            $gantry->register(new ErrorServiceProvider);
        }
 
            }
 
            throw new Twig_Error_Runtime(sprintf('Neither the property "%1$s" nor one of the methods "%1$s()", "get%1$s()"/"is%1$s()" or "__call()" exist and have public access in class "%2$s".', $item, $class), -1, $this->getSourceContext());
        }
 
        if ($isDefinedTest) {
            return true;
        }
 
        if ($this->env->hasExtension('Twig_Extension_Sandbox')) {
            $this->env->getExtension('Twig_Extension_Sandbox')->checkMethodAllowed($object, $method);
        }
 
        // Some objects throw exceptions when they have __call, and the method we try
        // to call is not supported. If ignoreStrictCheck is true, we should return null.
        try {
            if (!$arguments) {
                $ret = $object->$method();
            } else {
                $ret = call_user_func_array(array($object, $method), $arguments);
            }
        } catch (BadMethodCallException $e) {
            if ($call && ($ignoreStrictCheck || !$this->env->isStrictVariables())) {
                return;
            }
            throw $e;
        }
 
        // @deprecated in 1.28
        if ($object instanceof Twig_TemplateInterface) {
            $self = $object->getTemplateName() === $this->getTemplateName();
            $message = sprintf('Calling "%s" on template "%s" from template "%s" is deprecated since version 1.28 and won\'t be supported anymore in 2.0.', $item, $object->getTemplateName(), $this->getTemplateName());
            if ('renderBlock' === $method || 'displayBlock' === $method) {
                $message .= sprintf(' Use block("%s"%s) instead).', $arguments[0], $self ? '' : ', template');
            } elseif ('hasBlock' === $method) {
                $message .= sprintf(' Use "block("%s"%s) is defined" instead).', $arguments[0], $self ? '' : ', template');
            } elseif ('render' === $method || 'display' === $method) {
                $message .= sprintf(' Use include("%s") instead).', $object->getTemplateName());
            }
            @trigger_error($message, E_USER_DEPRECATED);
            'particle' => array($this, 'block_particle'),
        );
    }
 
    protected function doGetParent(array $context)
    {
        return "@nucleus/partials/particle.html.twig";
    }
 
    protected function doDisplay(array $context, array $blocks = array())
    {
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }
 
    // line 3
    public function block_particle($context, array $blocks = array())
    {
        // line 4
        echo "    ";
        $context["html"] = (($this->getAttribute(($context["particle"] ?? null), "twig", array())) ? ($this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "compile", array(0 => $this->getAttribute(($context["particle"] ?? null), "html", array())), "method")) : ($this->getAttribute(($context["particle"] ?? null), "html", array())));
        // line 5
        echo "    ";
        echo $this->env->getExtension('Gantry\Component\Twig\TwigExtension')->htmlFilter((($this->getAttribute(($context["particle"] ?? null), "filter", array())) ? ($this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "platform", array()), "filter", array(0 => ($context["html"] ?? null)), "method")) : (($context["html"] ?? null))));
        echo "
";
    }
 
    public function getTemplateName()
    {
        return "@particles/custom.html.twig";
    }
 
    public function isTraitable()
    {
        return false;
    }
 
    public function getDebugInfo()
    {
        return array (  34 => 5,  31 => 4,  28 => 3,  11 => 1,);
 
        if ($useBlocks && isset($blocks[$name])) {
            $template = $blocks[$name][0];
            $block = $blocks[$name][1];
        } elseif (isset($this->blocks[$name])) {
            $template = $this->blocks[$name][0];
            $block = $this->blocks[$name][1];
        } else {
            $template = null;
            $block = null;
        }
 
        // avoid RCEs when sandbox is enabled
        if (null !== $template && !$template instanceof self) {
            throw new LogicException('A block must be a method on a Twig_Template instance.');
        }
 
        if (null !== $template) {
            try {
                $template->$block($context, $blocks);
            } catch (Twig_Error $e) {
                if (!$e->getSourceContext()) {
                    $e->setSourceContext($template->getSourceContext());
                }
 
                // this is mostly useful for Twig_Error_Loader exceptions
                // see Twig_Error_Loader
                if (false === $e->getTemplateLine()) {
                    $e->setTemplateLine(-1);
                    $e->guess();
                }
 
                throw $e;
            } catch (Exception $e) {
                throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $template->getSourceContext(), $e);
            }
        } elseif (false !== $parent = $this->getParent($context)) {
            $parent->displayBlock($name, $context, array_merge($this->blocks, $blocks), false);
        } else {
            @trigger_error(sprintf('Silent display of undefined block "%s" in template "%s" is deprecated since version 1.29 and will throw an exception in 2.0. Use the "block(\'%s\') is defined" expression to test for block existence.', $name, $this->getTemplateName(), $name), E_USER_DEPRECATED);
        echo $assetFunction($content, $location, $priority);
        // line 9
        $assetFunction = $this->env->getFunction('parse_assets')->getCallable();
        $assetVariables = array();
        if ($assetVariables && !is_array($assetVariables)) {
            throw new UnexpectedValueException('{% scripts with x %}: x is not an array');
        }
        $location = "footer";
        if ($location && !is_string($location)) {
            throw new UnexpectedValueException('{% scripts in x %}: x is not a string');
        }
        $priority = isset($assetVariables['priority']) ? $assetVariables['priority'] : 0;
        ob_start();
        // line 10
        echo "    ";
        $this->displayBlock('javascript_footer', $context, $blocks);
        $content = ob_get_clean();
        echo $assetFunction($content, $location, $priority);
        // line 14
        $this->displayBlock('particle', $context, $blocks);
    }
 
    // line 2
    public function block_stylesheets($context, array $blocks = array())
    {
        // line 3
        echo "    ";
    }
 
    // line 5
    public function block_javascript($context, array $blocks = array())
    {
        // line 6
        echo "    ";
    }
 
    // line 10
    public function block_javascript_footer($context, array $blocks = array())
    {
        // line 11
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
{
    public function __construct(Twig_Environment $env)
    {
        parent::__construct($env);
 
        // line 1
        $this->parent = $this->loadTemplate("@nucleus/partials/particle.html.twig", "@particles/custom.html.twig", 1);
        $this->blocks = array(
            'particle' => array($this, 'block_particle'),
        );
    }
 
    protected function doGetParent(array $context)
    {
        return "@nucleus/partials/particle.html.twig";
    }
 
    protected function doDisplay(array $context, array $blocks = array())
    {
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }
 
    // line 3
    public function block_particle($context, array $blocks = array())
    {
        // line 4
        echo "    ";
        $context["html"] = (($this->getAttribute(($context["particle"] ?? null), "twig", array())) ? ($this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "compile", array(0 => $this->getAttribute(($context["particle"] ?? null), "html", array())), "method")) : ($this->getAttribute(($context["particle"] ?? null), "html", array())));
        // line 5
        echo "    ";
        echo $this->env->getExtension('Gantry\Component\Twig\TwigExtension')->htmlFilter((($this->getAttribute(($context["particle"] ?? null), "filter", array())) ? ($this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "platform", array()), "filter", array(0 => ($context["html"] ?? null)), "method")) : (($context["html"] ?? null))));
        echo "
";
    }
 
    public function getTemplateName()
    {
        return "@particles/custom.html.twig";
    }
 
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
                    echo "            ";
                    $context["particle"] = $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "config", array()), "getJoined", array(0 => ("particles." . $this->getAttribute(($context["segment"] ?? null), "subtype", array())), 1 => $this->getAttribute(($context["segment"] ?? null), "attributes", array())), "method");
                    // line 10
                    echo "        ";
                }
                // line 11
                echo "    ";
            }
            // line 12
            echo "
    ";
            // line 13
            ob_start();
            // line 14
            echo "        ";
            if ((($context["enabled"] ?? null) && ((null === $this->getAttribute($this->getAttribute(($context["segment"] ?? null), "attributes", array()), "enabled", array())) || $this->getAttribute($this->getAttribute(($context["segment"] ?? null), "attributes", array()), "enabled", array())))) {
                // line 15
                echo "            ";
                $this->loadTemplate(array(0 => (("particles/" . $this->getAttribute(($context["segment"] ?? null), "subtype", array())) . ".html.twig"), 1 => (("@particles/" . $this->getAttribute(                // line 16
($context["segment"] ?? null), "subtype", array())) . ".html.twig"), 2 => "@nucleus/content/missing.html.twig"), "@nucleus/content/particle.html.twig", 15)->display($context);
                // line 18
                echo "        ";
            }
            // line 19
            echo "    ";
            $context["html"] = ('' === $tmp = ob_get_clean()) ? '' : new Twig_Markup($tmp, $this->env->getCharset());
            // line 20
            echo "    ";
            $context["html"] = twig_trim_filter(($context["html"] ?? null));
            // line 21
            echo "
    ";
            // line 22
            $context["classes"] = twig_trim_filter(((( !($context["inContent"] ?? null)) ? ("g-content g-particle ") : ("g-particle ")) . twig_join_filter($this->getAttribute(($context["segment"] ?? null), "classes", array()), " ")));
            // line 23
            if (($context["html"] ?? null)) {
                // line 24
                if ($this->getAttribute(($context["gantry"] ?? null), "debug", array())) {
                    echo "<!-- START PARTICLE ";
                    echo twig_escape_filter($this->env, ($context["id"] ?? null), "html", null, true);
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
        @trigger_error(sprintf('The %s method is deprecated since version 1.22 and will be removed in Twig 2.0.', __METHOD__), E_USER_DEPRECATED);
 
        return $this->templateClassPrefix;
    }
 
    /**
     * Renders a template.
     *
     * @param string $name    The template name
     * @param array  $context An array of parameters to pass to the template
     *
     * @return string The rendered template
     *
     * @throws Twig_Error_Loader  When the template cannot be found
     * @throws Twig_Error_Syntax  When an error occurred during compilation
     * @throws Twig_Error_Runtime When an error occurred during rendering
     */
    public function render($name, array $context = array())
    {
        return $this->loadTemplate($name)->render($context);
    }
 
    /**
     * Displays a template.
     *
     * @param string $name    The template name
     * @param array  $context An array of parameters to pass to the template
     *
     * @throws Twig_Error_Loader  When the template cannot be found
     * @throws Twig_Error_Syntax  When an error occurred during compilation
     * @throws Twig_Error_Runtime When an error occurred during rendering
     */
    public function display($name, array $context = array())
    {
        $this->loadTemplate($name)->display($context);
    }
 
    /**
     * Loads a template.
     *
 
            $this->renderer = $this->extendTwig($twig, $loader);
        }
 
        return $this->renderer;
    }
 
    /**
     * Render a template file by using given context.
     *
     * @param string $file
     * @param array $context
     * @return string
     */
    public function render($file, array $context = [])
    {
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $this->renderer()->render($file, $context);
    }
 
    /**
     * Compile and render twig string.
     *
     * @param string $string
     * @param array $context
     * @return string
     */
    public function compile($string, array $context = [])
    {
        $renderer = $this->renderer();
        $template = $renderer->createTemplate($string);
 
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $template->render($context);
    }
 
 
            $filename = $locator->findResource("gantry-cache://theme/html/{$key}.php", true, true);
            $file = PhpFile::instance($filename);
            if ($file->exists()) {
                try {
                    return ContentBlock::fromArray((array) $file->content());
                } catch (\Exception $e) {
                    // Invalid cache, continue to rendering.
                    GANTRY_DEBUGGER && \Gantry\Debugger::addMessage(sprintf('Failed to load %s %s cache', $item->type, $item->id), 'debug');
                }
            }
        }
 
        // Create new document context for assets.
        $context = $this->getContext(['segment' => $item, 'enabled' => 1, 'particle' => $particle] + $options);
 
        /** @var Document $document */
        $document = $gantry['document'];
        $document->push();
        $html = trim($this->render("@nucleus/content/{$item->type}.html.twig", $context));
        $content = $document->pop()->setContent($html);
 
        if (isset($file)) {
            // Save HTML and assets into the cache.
            GANTRY_DEBUGGER && \Gantry\Debugger::addMessage(sprintf('Caching %s %s', $item->type, $item->id), 'debug');
            $file->save($content->toArray());
        }
 
        return $content;
    }
}
 
                        }
                    }
            }
        }
    }
 
    /**
     * Renders individual content block, like particle or position.
     *
     * Function is used to pre-render content.
     *
     * @param object|array $item
     * @param array $options
     * @return string|null
     */
    public function renderContent($item, $options = [])
    {
        $gantry = static::gantry();
 
        $content = $this->getContent($item, $options);
 
        /** @var Document $document */
        $document = $gantry['document'];
        $document->addBlock($content);
 
        $html = $content->toString();
        return !strstr($html, '@@DEFERRED@@') ? $html : null;
    }
 
    /**
     * Renders individual content block, like particle or position.
     *
     * Function is used to pre-render content.
     *
     * @param object|array $item
     * @param array $options
     * @return ContentBlock
     * @since 5.4.3
     */
    public function getContent($item, $options = [])
                $fixed = true;
                foreach ($item->children as $child) {
                    $fixed &= !empty($child->attributes->fixed);
                }
 
                $this->prepareLayout($item->children, $fixed, $temporary);
            }
 
            // TODO: remove hard coded types.
            switch ($item->type) {
                case 'system':
                    break;
 
                case 'atom':
                case 'particle':
                case 'position':
                case 'spacer':
                    GANTRY_DEBUGGER && \Gantry\Debugger::startTimer($item->id, "Rendering {$item->id}");
 
                    $item->content = $this->renderContent($item, ['prepare_layout' => true]);
                    // Note that content can also be null (postpone rendering).
                    if ($item->content === '') {
                        unset($items[$i]);
                    }
 
                    GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer($item->id);
 
                    break;
 
                default:
                    if ($sticky) {
                        $item->attributes->sticky = 1;
                        break;
                    }
 
                    if (empty($item->children)) {
                        unset($items[$i]);
                        break;
                    }
 
     * @param array $items
     * @param bool  $temporary
     * @param bool  $sticky
     * @internal
     */
    protected function prepareLayout(array &$items, $temporary = false, $sticky = false)
    {
        foreach ($items as $i => &$item) {
            // Non-numeric items are meta-data which should be ignored.
            if (((string)(int) $i !== (string) $i) || !is_object($item)) {
                continue;
            }
 
            if (!empty($item->children)) {
                $fixed = true;
                foreach ($item->children as $child) {
                    $fixed &= !empty($child->attributes->fixed);
                }
 
                $this->prepareLayout($item->children, $fixed, $temporary);
            }
 
            // TODO: remove hard coded types.
            switch ($item->type) {
                case 'system':
                    break;
 
                case 'atom':
                case 'particle':
                case 'position':
                case 'spacer':
                    GANTRY_DEBUGGER && \Gantry\Debugger::startTimer($item->id, "Rendering {$item->id}");
 
                    $item->content = $this->renderContent($item, ['prepare_layout' => true]);
                    // Note that content can also be null (postpone rendering).
                    if ($item->content === '') {
                        unset($items[$i]);
                    }
 
                    GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer($item->id);
     * @param array $items
     * @param bool  $temporary
     * @param bool  $sticky
     * @internal
     */
    protected function prepareLayout(array &$items, $temporary = false, $sticky = false)
    {
        foreach ($items as $i => &$item) {
            // Non-numeric items are meta-data which should be ignored.
            if (((string)(int) $i !== (string) $i) || !is_object($item)) {
                continue;
            }
 
            if (!empty($item->children)) {
                $fixed = true;
                foreach ($item->children as $child) {
                    $fixed &= !empty($child->attributes->fixed);
                }
 
                $this->prepareLayout($item->children, $fixed, $temporary);
            }
 
            // TODO: remove hard coded types.
            switch ($item->type) {
                case 'system':
                    break;
 
                case 'atom':
                case 'particle':
                case 'position':
                case 'spacer':
                    GANTRY_DEBUGGER && \Gantry\Debugger::startTimer($item->id, "Rendering {$item->id}");
 
                    $item->content = $this->renderContent($item, ['prepare_layout' => true]);
                    // Note that content can also be null (postpone rendering).
                    if ($item->content === '') {
                        unset($items[$i]);
                    }
 
                    GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer($item->id);
     * @param array $items
     * @param bool  $temporary
     * @param bool  $sticky
     * @internal
     */
    protected function prepareLayout(array &$items, $temporary = false, $sticky = false)
    {
        foreach ($items as $i => &$item) {
            // Non-numeric items are meta-data which should be ignored.
            if (((string)(int) $i !== (string) $i) || !is_object($item)) {
                continue;
            }
 
            if (!empty($item->children)) {
                $fixed = true;
                foreach ($item->children as $child) {
                    $fixed &= !empty($child->attributes->fixed);
                }
 
                $this->prepareLayout($item->children, $fixed, $temporary);
            }
 
            // TODO: remove hard coded types.
            switch ($item->type) {
                case 'system':
                    break;
 
                case 'atom':
                case 'particle':
                case 'position':
                case 'spacer':
                    GANTRY_DEBUGGER && \Gantry\Debugger::startTimer($item->id, "Rendering {$item->id}");
 
                    $item->content = $this->renderContent($item, ['prepare_layout' => true]);
                    // Note that content can also be null (postpone rendering).
                    if ($item->content === '') {
                        unset($items[$i]);
                    }
 
                    GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer($item->id);
                }
            }
 
            GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer('atoms');
        }
    }
 
    /**
     * Returns all non-empty segments from the layout.
     *
     * @return array
     */
    public function segments()
    {
        if (!isset($this->segments)) {
            $this->segments = $this->loadLayout()->toArray();
 
            GANTRY_DEBUGGER && \Gantry\Debugger::startTimer('segments', "Preparing layout");
 
            $this->prepareLayout($this->segments);
 
            GANTRY_DEBUGGER && \Gantry\Debugger::stopTimer('segments');
        }
 
        return $this->segments;
    }
 
    /**
     * Prepare layout for rendering. Initializes all CSS/JS in particles.
     */
    public function prepare()
    {
        $this->segments();
    }
 
    /**
     * Returns details of the theme.
     *
     * @return ThemeDetails
     */
            if ($ignoreStrictCheck || !$this->env->isStrictVariables()) {
                return;
            }
 
            throw new Twig_Error_Runtime(sprintf('Neither the property "%1$s" nor one of the methods "%1$s()", "get%1$s()"/"is%1$s()" or "__call()" exist and have public access in class "%2$s".', $item, $class), -1, $this->getSourceContext());
        }
 
        if ($isDefinedTest) {
            return true;
        }
 
        if ($this->env->hasExtension('Twig_Extension_Sandbox')) {
            $this->env->getExtension('Twig_Extension_Sandbox')->checkMethodAllowed($object, $method);
        }
 
        // Some objects throw exceptions when they have __call, and the method we try
        // to call is not supported. If ignoreStrictCheck is true, we should return null.
        try {
            if (!$arguments) {
                $ret = $object->$method();
            } else {
                $ret = call_user_func_array(array($object, $method), $arguments);
            }
        } catch (BadMethodCallException $e) {
            if ($call && ($ignoreStrictCheck || !$this->env->isStrictVariables())) {
                return;
            }
            throw $e;
        }
 
        // @deprecated in 1.28
        if ($object instanceof Twig_TemplateInterface) {
            $self = $object->getTemplateName() === $this->getTemplateName();
            $message = sprintf('Calling "%s" on template "%s" from template "%s" is deprecated since version 1.28 and won\'t be supported anymore in 2.0.', $item, $object->getTemplateName(), $this->getTemplateName());
            if ('renderBlock' === $method || 'displayBlock' === $method) {
                $message .= sprintf(' Use block("%s"%s) instead).', $arguments[0], $self ? '' : ', template');
            } elseif ('hasBlock' === $method) {
                $message .= sprintf(' Use "block("%s"%s) is defined" instead).', $arguments[0], $self ? '' : ', template');
            } elseif ('render' === $method || 'display' === $method) {
                $message .= sprintf(' Use include("%s") instead).', $object->getTemplateName());
            'page_bottom' => array($this, 'block_page_bottom'),
            'body_top' => array($this, 'block_body_top'),
            'body_bottom' => array($this, 'block_body_bottom'),
            'page_head' => array($this, 'block_page_head'),
            'page_footer' => array($this, 'block_page_footer'),
            'page' => array($this, 'block_page'),
            'page_body' => array($this, 'block_page_body'),
        );
    }
 
    protected function doDisplay(array $context, array $blocks = array())
    {
        // line 1
        $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "debugger", array()), "startTimer", array(0 => "render", 1 => "Rendering page"), "method");
        // line 2
        $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "setLayout", array(), "method");
        // line 3
        $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "loadAtoms", array(), "method");
        // line 4
        $context["segments"] = $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "segments", array(), "method");
        // line 6
        ob_start();
        // line 7
        echo "    ";
        if ($this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "theme", array()), "hasContent", array(), "method")) {
            // line 8
            echo "        ";
            $this->displayBlock('content', $context, $blocks);
            // line 10
            echo "    ";
        }
        $context["content"] = ('' === $tmp = ob_get_clean()) ? '' : new Twig_Markup($tmp, $this->env->getCharset());
        // line 13
        $context["offcanvas"] = null;
        // line 14
        $context['_parent'] = $context;
        $context['_seq'] = twig_ensure_traversable(($context["segments"] ?? null));
        foreach ($context['_seq'] as $context["_key"] => $context["segment"]) {
            if (($this->getAttribute($context["segment"], "type", array()) == "offcanvas")) {
                // line 15
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
{
    public function __construct(Twig_Environment $env)
    {
        parent::__construct($env);
 
        // line 1
        $this->parent = $this->loadTemplate("@nucleus/page.html.twig", "partials/page.html.twig", 1);
        $this->blocks = array(
            'page_footer' => array($this, 'block_page_footer'),
        );
    }
 
    protected function doGetParent(array $context)
    {
        return "@nucleus/page.html.twig";
    }
 
    protected function doDisplay(array $context, array $blocks = array())
    {
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }
 
    // line 3
    public function block_page_footer($context, array $blocks = array())
    {
        // line 4
        echo "    ";
        $this->displayParentBlock("page_footer", $context, $blocks);
        echo "
    <jdoc:include type=\"modules\" name=\"debug\" />
";
    }
 
    public function getTemplateName()
    {
        return "partials/page.html.twig";
    }
 
    public function isTraitable()
    {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
{
    public function __construct(Twig_Environment $env)
    {
        parent::__construct($env);
 
        // line 1
        $this->parent = $this->loadTemplate("partials/page.html.twig", "index.html.twig", 1);
        $this->blocks = array(
            'content' => array($this, 'block_content'),
        );
    }
 
    protected function doGetParent(array $context)
    {
        return "partials/page.html.twig";
    }
 
    protected function doDisplay(array $context, array $blocks = array())
    {
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }
 
    // line 3
    public function block_content($context, array $blocks = array())
    {
        // line 4
        echo "    ";
        echo $this->getAttribute($this->getAttribute(($context["gantry"] ?? null), "platform", array()), "displayContent", array(0 => ($context["content"] ?? null)), "method");
        echo "
";
    }
 
    public function getTemplateName()
    {
        return "index.html.twig";
    }
 
    public function isTraitable()
    {
        return false;
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
            $this->doDisplay($context, $blocks);
        } catch (Twig_Error $e) {
            if (!$e->getSourceContext()) {
                $e->setSourceContext($this->getSourceContext());
            }
 
            // this is mostly useful for Twig_Error_Loader exceptions
            // see Twig_Error_Loader
            if (false === $e->getTemplateLine()) {
                $e->setTemplateLine(-1);
                $e->guess();
            }
 
            throw $e;
        } catch (Exception $e) {
            throw new Twig_Error_Runtime(sprintf('An exception has been thrown during the rendering of a template ("%s").', $e->getMessage()), -1, $this->getSourceContext(), $e);
        }
    }
 
    /**
     * Auto-generated method to display the template with the given context.
    }
 
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
     * @return array An array of blocks
     *
     * @internal
     */
    public function getBlocks()
    {
        return $this->blocks;
    }
 
    public function display(array $context, array $blocks = array())
    {
        $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
    }
 
    public function render(array $context)
    {
        $level = ob_get_level();
        ob_start();
        try {
            $this->display($context);
        } catch (Exception $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        } catch (Throwable $e) {
            while (ob_get_level() > $level) {
                ob_end_clean();
            }
 
            throw $e;
        }
 
        return ob_get_clean();
    }
 
    protected function displayWithErrorHandling(array $context, array $blocks = array())
    {
        try {
        @trigger_error(sprintf('The %s method is deprecated since version 1.22 and will be removed in Twig 2.0.', __METHOD__), E_USER_DEPRECATED);
 
        return $this->templateClassPrefix;
    }
 
    /**
     * Renders a template.
     *
     * @param string $name    The template name
     * @param array  $context An array of parameters to pass to the template
     *
     * @return string The rendered template
     *
     * @throws Twig_Error_Loader  When the template cannot be found
     * @throws Twig_Error_Syntax  When an error occurred during compilation
     * @throws Twig_Error_Runtime When an error occurred during rendering
     */
    public function render($name, array $context = array())
    {
        return $this->loadTemplate($name)->render($context);
    }
 
    /**
     * Displays a template.
     *
     * @param string $name    The template name
     * @param array  $context An array of parameters to pass to the template
     *
     * @throws Twig_Error_Loader  When the template cannot be found
     * @throws Twig_Error_Syntax  When an error occurred during compilation
     * @throws Twig_Error_Runtime When an error occurred during rendering
     */
    public function display($name, array $context = array())
    {
        $this->loadTemplate($name)->display($context);
    }
 
    /**
     * Loads a template.
     *
 
            $this->renderer = $this->extendTwig($twig, $loader);
        }
 
        return $this->renderer;
    }
 
    /**
     * Render a template file by using given context.
     *
     * @param string $file
     * @param array $context
     * @return string
     */
    public function render($file, array $context = [])
    {
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $this->renderer()->render($file, $context);
    }
 
    /**
     * Compile and render twig string.
     *
     * @param string $string
     * @param array $context
     * @return string
     */
    public function compile($string, array $context = [])
    {
        $renderer = $this->renderer();
        $template = $renderer->createTemplate($string);
 
        // Include Gantry specific things to the context.
        $context = $this->getContext($context);
 
        return $template->render($context);
    }
 
 * @author    RocketTheme http://www.rockettheme.com
 * @copyright Copyright (C) 2007 - 2017 RocketTheme, LLC
 * @license   GNU/GPLv2 and later
 *
 * http://www.gnu.org/licenses/gpl-2.0.html
 */
 
defined('_JEXEC') or die;
 
// Bootstrap Gantry framework or fail gracefully (inside included file).
$gantry = include __DIR__ . '/includes/gantry.php';
 
/** @var \Gantry\Framework\Theme $theme */
$theme = $gantry['theme'];
 
// All the custom twig variables can be defined in here:
$context = array();
 
// Render the page.
echo $theme->render('index.html.twig', $context);
 
     * @param   string  $directory  The name of the template
     * @param   string  $filename   The actual filename
     *
     * @return  string  The contents of the template
     *
     * @since   11.1
     */
    protected function _loadTemplate($directory, $filename)
    {
        $contents = '';
 
        // Check to see if we have a valid template file
        if (file_exists($directory . '/' . $filename))
        {
            // Store the file path
            $this->_file = $directory . '/' . $filename;
 
            // Get the file content
            ob_start();
            require $directory . '/' . $filename;
            $contents = ob_get_contents();
            ob_end_clean();
        }
 
        // Try to find a favicon by checking the template and root folder
        $icon = '/favicon.ico';
 
        foreach (array($directory, JPATH_BASE) as $dir)
        {
            if (file_exists($dir . $icon))
            {
                $path = str_replace(JPATH_BASE, '', $dir);
                $path = str_replace('\\', '/', $path);
                $this->addFavicon(JUri::base(true) . $path . $icon);
                break;
            }
        }
 
        return $contents;
    }
 
        if (!file_exists($directory . '/' . $template . '/' . $file))
        {
            $file = 'index.php';
        }
 
        // Load the language file for the template
        $lang = JFactory::getLanguage();
 
        // 1.5 or core then 1.6
        $lang->load('tpl_' . $template, JPATH_BASE, null, false, true)
            || $lang->load('tpl_' . $template, $directory . '/' . $template, null, false, true);
 
        // Assign the variables
        $this->template = $template;
        $this->baseurl = JUri::base(true);
        $this->params = isset($params['params']) ? $params['params'] : new Registry;
 
        // Load
        $this->_template = $this->_loadTemplate($directory . '/' . $template, $file);
 
        return $this;
    }
 
    /**
     * Parse a document template
     *
     * @return  JDocumentHTML  instance of $this to allow chaining
     *
     * @since   11.1
     */
    protected function _parseTemplate()
    {
        $matches = array();
 
        if (preg_match_all('#<jdoc:include\ type="([^"]+)"(.*)\/>#iU', $this->_template, $matches))
        {
            $template_tags_first = array();
            $template_tags_last = array();
 
            $options['title'] = (isset($args[3])) ? $args[3] : null;
        }
 
        parent::$_buffer[$options['type']][$options['name']][$options['title']] = $content;
 
        return $this;
    }
 
    /**
     * Parses the template and populates the buffer
     *
     * @param   array  $params  Parameters for fetching the template
     *
     * @return  JDocumentHTML instance of $this to allow chaining
     *
     * @since   11.1
     */
    public function parse($params = array())
    {
        return $this->_fetchTemplate($params)->_parseTemplate();
    }
 
    /**
     * Outputs the template to the browser.
     *
     * @param   boolean  $caching  If true, cache the output
     * @param   array    $params   Associative array of attributes
     *
     * @return  string The rendered data
     *
     * @since   11.1
     */
    public function render($caching = false, $params = array())
    {
        $this->_caching = $caching;
 
        if (empty($this->_template))
        {
            $this->parse($params);
        }
     */
    protected function render()
    {
        // Setup the document options.
        $this->docOptions['template'] = $this->get('theme');
        $this->docOptions['file']     = $this->get('themeFile', 'index.php');
        $this->docOptions['params']   = $this->get('themeParams');
 
        if ($this->get('themes.base'))
        {
            $this->docOptions['directory'] = $this->get('themes.base');
        }
        // Fall back to constants.
        else
        {
            $this->docOptions['directory'] = defined('JPATH_THEMES') ? JPATH_THEMES : (defined('JPATH_BASE') ? JPATH_BASE : __DIR__) . '/themes';
        }
 
        // Parse the document.
        $this->document->parse($this->docOptions);
 
        // Trigger the onBeforeRender event.
        JPluginHelper::importPlugin('system');
        $this->triggerEvent('onBeforeRender');
 
        $caching = false;
 
        if ($this->isClient('site') && $this->get('caching') && $this->get('caching', 2) == 2 && !JFactory::getUser()->get('id'))
        {
            $caching = true;
        }
 
        // Render the document.
        $data = $this->document->render($caching, $this->docOptions);
 
        // Set the application output data.
        $this->setBody($data);
 
        // Trigger the onAfterRender event.
        $this->triggerEvent('onAfterRender');
                    $this->setUserState('users.login.form.data', array('return' => JUri::getInstance()->toString()));
                    $this->set('themeFile', 'offline.php');
                    $this->setHeader('Status', '503 Service Temporarily Unavailable', 'true');
                }
 
                if (!is_dir(JPATH_THEMES . '/' . $template->template) && !$this->get('offline'))
                {
                    $this->set('themeFile', 'component.php');
                }
 
                // Ensure themeFile is set by now
                if ($this->get('themeFile') == '')
                {
                    $this->set('themeFile', $file . '.php');
                }
 
                break;
        }
 
        parent::render();
    }
 
    /**
     * Route the application.
     *
     * Routing is the process of examining the request environment to determine which
     * component should receive the request. The component optional parameters
     * are then set in the request object to be processed when the application is being
     * dispatched.
     *
     * @return  void
     *
     * @since   3.2
     */
    protected function route()
    {
        // Execute the parent method
        parent::route();
 
        $Itemid = $this->input->getInt('Itemid', null);
        }
    }
 
    /**
     * Execute the application.
     *
     * @return  void
     *
     * @since   3.2
     */
    public function execute()
    {
        // Perform application routines.
        $this->doExecute();
 
        // If we have an application document object, render it.
        if ($this->document instanceof JDocument)
        {
            // Render the application output.
            $this->render();
        }
 
        // If gzip compression is enabled in configuration and the server is compliant, compress the output.
        if ($this->get('gzip') && !ini_get('zlib.output_compression') && ini_get('output_handler') !== 'ob_gzhandler')
        {
            $this->compress();
 
            // Trigger the onAfterCompress event.
            $this->triggerEvent('onAfterCompress');
        }
 
        // Send the application response.
        $this->respond();
 
        // Trigger the onAfterRespond event.
        $this->triggerEvent('onAfterRespond');
    }
 
    /**
     * Check if the user is required to reset their password.
{
    include_once __DIR__ . '/defines.php';
}
 
if (!defined('_JDEFINES'))
{
    define('JPATH_BASE', __DIR__);
    require_once JPATH_BASE . '/includes/defines.php';
}
 
require_once JPATH_BASE . '/includes/framework.php';
 
// Set profiler start time and memory usage and mark afterLoad in the profiler.
JDEBUG ? JProfiler::getInstance('Application')->setStart($startTime, $startMem)->mark('afterLoad') : null;
 
// Instantiate the application.
$app = JFactory::getApplication('site');
 
// Execute the application.
$app->execute();
 

Environment & details:

Key Value
Itemid 894
option com_payplans
view plan
task login
plan_id 17
empty
empty
empty
empty
Key Value
REDIRECT_HTTPS on
REDIRECT_HTTP_AUTHORIZATION
REDIRECT_STATUS 200
HTTPS on
HTTP_AUTHORIZATION
HTTP_HOST in.onlinelogomaker.com
HTTP_CONNECTION Keep-Alive
HTTP_ACCEPT_ENCODING gzip, br
HTTP_X_FORWARDED_FOR 44.206.248.122
HTTP_CF_RAY 866c8f202d655b64-EWR
HTTP_X_FORWARDED_PROTO https
HTTP_CF_VISITOR {"scheme":"https"}
HTTP_ACCEPT */*
HTTP_USER_AGENT claudebot
HTTP_REFERER https://in.onlinelogomaker.com/premium-all
HTTP_CF_CONNECTING_IP 44.206.248.122
HTTP_CDN_LOOP cloudflare
HTTP_CF_IPCOUNTRY US
PATH /sbin:/usr/sbin:/bin:/usr/bin
SERVER_SIGNATURE <address>Apache/2.2.15 (CentOS) Server at in.onlinelogomaker.com Port 80</address>
SERVER_SOFTWARE Apache/2.2.15 (CentOS)
SERVER_NAME in.onlinelogomaker.com
SERVER_ADDR 165.227.81.221
SERVER_PORT 80
REMOTE_ADDR 44.206.248.122
DOCUMENT_ROOT /home/online78/public_html/
SERVER_ADMIN root@localhost
SCRIPT_FILENAME /home/online78/public_html/index.php
REMOTE_PORT 9444
REDIRECT_URL /membership/plan/login/17
GATEWAY_INTERFACE CGI/1.1
SERVER_PROTOCOL HTTP/1.1
REQUEST_METHOD GET
QUERY_STRING
REQUEST_URI /membership/plan/login/17
SCRIPT_NAME /index.php
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1710841835.559
REQUEST_TIME 1710841835
empty
0. Whoops\Handler\PrettyPageHandler