Deprecated: Phalcon\Http\Cookie::setDomain(): Passing null to parameter #1 ($domain) of type string is deprecated in /var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Language.php on line 46
ParseError: Unclosed '{' on line 70
Phalcon Framework 5.8.0

ParseError: Unclosed '{' on line 70

/var/www/html/discounts-n-coupons.com/cache/volt/Tmpl_Site_PhalCMS_Post_Show.volt.php (75)
#0Phalcon\Mvc\View\Engine\Volt->render
#1Phalcon\Mvc\View->engineRender
#2Phalcon\Mvc\View->processRender
#3Phalcon\Mvc\View->render
#4Phalcon\Mvc\Application->handle
/var/www/html/discounts-n-coupons.com/src/app/Lib/CmsApplication.php (117)
<?php
 
namespace CLSystems\PhalCMS\Lib;
 
use Phalcon\Autoload\Loader;
use Phalcon\Http\Response;
use Phalcon\Events\Event;
use Phalcon\Mvc\Application;
use Phalcon\Mvc\Dispatcher;
use Phalcon\Mvc\View;
use CLSystems\PhalCMS\Lib\Helper\Asset;
use CLSystems\PhalCMS\Lib\Helper\Config;
use CLSystems\PhalCMS\Lib\Helper\Uri;
use CLSystems\PhalCMS\Lib\Helper\State;
use CLSystems\PhalCMS\Lib\Helper\User;
use CLSystems\PhalCMS\Lib\Helper\Event as EventHelper;
use CLSystems\PhalCMS\Lib\Mvc\View\ViewBase;
use CLSystems\Php\Registry;
use MatthiasMullie\Minify;
use Exception;
 
class CmsApplication extends Application
{
    public function execute()
    {
        try {
            $eventsManager = $this->di->getShared('eventsManager');
            $eventsManager->attach('application:beforeSendResponse', $this);
            $plugins = EventHelper::getPlugins();
            $systemEvents = [
                'application:beforeSendResponse',
                'dispatch:beforeExecuteRoute',
                'dispatch:beforeException',
                'dispatch:beforeDispatch',
                'dispatch:afterDispatch',
                'dispatch:afterInitialize',
            ];
 
            foreach ($plugins['System'] as $className => $config) {
                $handler = EventHelper::getHandler($className, $config);
 
                foreach ($systemEvents as $systemEvent) {
                    $eventsManager->attach($systemEvent, $handler);
                }
            }
 
            // Update view dirs
            define('TPL_SITE_PATH', APP_PATH . '/Tmpl/Site/' . Config::get('siteTemplate', 'PhalCMS'));
            define('TPL_ADMINISTRATOR_PATH', APP_PATH . '/Tmpl/Administrator');
            define('TPL_SYSTEM_PATH', APP_PATH . '/Tmpl/System');
 
            if (Uri::isClient('site')) {
                $viewDirs = [
                    TPL_SITE_PATH . '/Tmpl/',
                    TPL_SITE_PATH . '/',
                ];
            } else {
                $viewDirs = [
                    TPL_ADMINISTRATOR_PATH . '/',
                ];
            }
 
            foreach (['System', 'Cms'] as $plgGroup) {
                if (isset($plugins[$plgGroup])) {
                    /**
                     * @var string $pluginClass
                     * @var Registry $pluginConfig
                     */
 
 
                    foreach ($plugins[$plgGroup] as $pluginClass => $pluginConfig) {
                        $pluginName = $pluginConfig->get('manifest.name');
                        $pluginPath = PLUGIN_PATH . '/' . $plgGroup . '/' . $pluginName;
                        $psrPaths = [];
 
                        if (is_dir($pluginPath . '/Tmpl')) {
                            $viewDirs[] = $pluginPath . '/Tmpl/';
                        }
 
                        if (is_dir($pluginPath . '/Lib')) {
                            $psrPaths['CLSystems\\PhalCMS\\Lib'] = $pluginPath . '/Lib';
                        }
 
                        if (is_dir($pluginPath . '/Widget')) {
                            $psrPaths['CLSystems\\PhalCMS\\Widget'] = $pluginPath . '/Widget';
                        }
 
                        if ($psrPaths) {
                            (new Loader)
                                ->setNamespaces($psrPaths, true)
                                ->register();
                        }
                    }
                }
            }
 
            $viewDirs[] = TPL_SYSTEM_PATH . '/';
 
            /** @var ViewBase $view */
            $view = $this->di->getShared('view');
            $requestUri = $_SERVER['REQUEST_URI'];
 
            if (Config::get('siteOffline') === 'Y'
                && !User::getInstance()->access('super')
            ) {
                $this->view->setMainView('Offline/Index');
 
                if (strpos($requestUri, '/user/') !== 0) {
                    $requestUri = '';
                }
            } else {
                $view->setMainView('Index');
            }
 
            $view->setViewsDir($viewDirs);
            $this->setEventsManager($eventsManager);
            $this->handle($requestUri)->send();
        } catch (Exception $e) {
            if (true === DEVELOPMENT_MODE) {
                // Let Phalcon Debug catch this
                throw $e;
            }
 
            try {
                if (User::getInstance()->access('super')) {
                    State::setMark('exception', $e);
                }
 
                /**
                 * @var Dispatcher $dispatcher
                 * @var View $view
                 */
                $dispatcher = $this->getDI()->getShared('dispatcher');
                $dispatcher->setControllerName(Uri::isClient('administrator') ? 'admin_error' : 'error');
                $dispatcher->setActionName('show');
                $dispatcher->setParams(
                    [
                        'code'    => $e->getCode(),
                        'message' => $e->getMessage(),
                    ]
                );
 
                $view = $this->getDI()->getShared('view');
                $view->start();
                $dispatcher->dispatch();
                $view->render(
                    $dispatcher->getControllerName(),
                    $dispatcher->getActionName(),
                    $dispatcher->getParams()
                );
                $view->finish();
                echo $view->getContent();
            } catch (Exception $e2) {
                debugVar($e2->getMessage());
            }
        }
    }
 
    protected function getCompressor($type)
    {
        if ('css' === $type) {
            $compressor = new Minify\CSS;
            $compressor->setImportExtensions(
                [
                    'gif' => 'data:image/gif',
                    'png' => 'data:image/png',
                    'svg' => 'data:image/svg+xml',
                ]
            );
        } else {
            $compressor = new Minify\JS;
        }
 
        return $compressor;
    }
 
    protected function compressAssets()
    {
        $basePath = PUBLIC_PATH . '/assets';
        $assets = Factory::getService('assets');
 
        foreach (Asset::getFiles() as $type => $files) {
            $fileName = md5(implode(':', $files)) . '.' . $type;
            $filePath = $basePath . '/compressed/' . $fileName;
            $fileUri = DOMAIN . '/assets/compressed/' . $fileName . (DEVELOPMENT_MODE ? '?' . time() : '');
            $hasAsset = is_file($filePath);
            $ucType = ucfirst($type);
            $addFunc = 'add' . $ucType;
 
            if ($hasAsset && !DEVELOPMENT_MODE) {
                call_user_func_array([$assets, $addFunc], [$fileUri, false]);
                continue;
            }
 
            $compressor = self::getCompressor($type);
 
            foreach ($files as $file) {
                $compressor->add($file);
            }
 
            if (!is_dir($basePath . '/compressed/')) {
                mkdir($basePath . '/compressed/', 0777, true);
            }
 
            if ($compressor->minify($filePath)) {
//                echo $filePath;
                $chmodFile = chmod($filePath, 0777);
                if (false === $chmodFile)
                {
                    touch($filePath);
                    chmod($filePath, 0777);
                }
                call_user_func_array([$assets, $addFunc], [$fileUri, false]);
            }
 
            unset($compressor);
        }
    }
 
    public function beforeSendResponse(Event $event, CmsApplication $app, Response $response)
    {
        $request = $this->di->getShared('request');
 
        if ($request->isAjax()) {
            return;
        }
 
        /** @var Asset $assets */
        $this->compressAssets();
        $assets = $this->di->getShared('assets');
 
        // Compress CSS
        ob_start();
        $assets->outputCss();
        $assets->outputInlineCss();
        $content = str_replace('</head>', ob_get_clean() . '</head>', $response->getContent());
 
        // Compress JS
        ob_start();
        $assets->outputJs();
        $assets->outputInlineJs();
        $code = Asset::getCode() . ob_get_clean();
 
        // Extra code (in the footer)
        $content = str_replace('</body>', $code . '</body>', $content);
        $response->setContent($content);
    }
}
#5CLSystems\PhalCMS\Lib\CmsApplication->execute
/var/www/html/discounts-n-coupons.com/public/index.php (14)
<?php
declare(strict_types=1);
 
error_reporting(E_ALL);
ini_set('display_errors', true);
 
use CLSystems\PhalCMS\Lib\Factory;
 
define('BASE_PATH', dirname(__DIR__));
 
require_once BASE_PATH . '/src/app/Lib/Factory.php';
 
// Execute application
Factory::getApplication()->execute();
KeyValue
_url/de/discount-codes/6-percent-discount-max-save-20-sitewide-coupon-at-geekbuying
KeyValue
PATH/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
TEMP/var/www/clients/client1/web1/tmp
TMPDIR/var/www/clients/client1/web1/tmp
TMP/var/www/clients/client1/web1/tmp
HOSTNAME
USERweb1
HOME/var/www/clients/client1/web1
SCRIPT_NAME/index.php
REQUEST_URI/de/discount-codes/6-percent-discount-max-save-20-sitewide-coupon-at-geekbuying
QUERY_STRING_url=/de/discount-codes/6-percent-discount-max-save-20-sitewide-coupon-at-geekbuying
REQUEST_METHODGET
SERVER_PROTOCOLHTTP/2.0
GATEWAY_INTERFACECGI/1.1
REDIRECT_QUERY_STRING_url=/de/discount-codes/6-percent-discount-max-save-20-sitewide-coupon-at-geekbuying
REDIRECT_URL/de/discount-codes/6-percent-discount-max-save-20-sitewide-coupon-at-geekbuying
REMOTE_PORT44447
SCRIPT_FILENAME/var/www/clients/client1/web1/web/index.php
SERVER_ADMINwebmaster@discounts-n-coupons.com
CONTEXT_DOCUMENT_ROOT/var/www/clients/client1/web1/web
CONTEXT_PREFIX
REQUEST_SCHEMEhttps
DOCUMENT_ROOT/var/www/clients/client1/web1/web
REMOTE_ADDR18.219.47.239
SERVER_PORT443
SERVER_ADDR207.244.255.14
SERVER_NAMEdiscounts-n-coupons.com
SERVER_SOFTWAREApache
SERVER_SIGNATURE
HTTP_HOSTdiscounts-n-coupons.com
HTTP_ACCEPT_ENCODINGgzip, br, zstd, deflate
HTTP_USER_AGENTMozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
HTTP_ACCEPT*/*
proxy-nokeepalive1
SSL_TLS_SNIdiscounts-n-coupons.com
HTTPSon
H2_STREAM_TAG1995388-17-1
H2_STREAM_ID1
H2_PUSHED_ON
H2_PUSHED
H2_PUSHoff
H2PUSHoff
HTTP2on
REDIRECT_STATUS200
REDIRECT_SSL_TLS_SNIdiscounts-n-coupons.com
REDIRECT_HTTPSon
REDIRECT_H2_STREAM_TAG1995388-17-1
REDIRECT_H2_STREAM_ID1
REDIRECT_H2_PUSHED_ON
REDIRECT_H2_PUSHED
REDIRECT_H2_PUSHoff
REDIRECT_H2PUSHoff
REDIRECT_HTTP2on
FCGI_ROLERESPONDER
PHP_SELF/index.php
REQUEST_TIME_FLOAT1732240175.9237
REQUEST_TIME1732240175
#Path
0/var/www/html/discounts-n-coupons.com/public/index.php
1/var/www/html/discounts-n-coupons.com/src/app/Lib/Factory.php
2/var/www/html/discounts-n-coupons.com/src/app/Config/Define.php
3/var/www/html/discounts-n-coupons.com/src/app/Config/Loader.php
4/var/www/html/discounts-n-coupons.com/vendor/autoload.php
5/var/www/html/discounts-n-coupons.com/vendor/composer/autoload_real.php
6/var/www/html/discounts-n-coupons.com/vendor/composer/platform_check.php
7/var/www/html/discounts-n-coupons.com/vendor/composer/ClassLoader.php
8/var/www/html/discounts-n-coupons.com/vendor/composer/autoload_static.php
9/var/www/html/discounts-n-coupons.com/vendor/myclabs/deep-copy/src/DeepCopy/deep_copy.php
10/var/www/html/discounts-n-coupons.com/vendor/phpunit/phpunit/src/Framework/Assert/Functions.php
11/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-mbstring/bootstrap.php
12/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-mbstring/bootstrap80.php
13/var/www/html/discounts-n-coupons.com/vendor/symfony/deprecation-contracts/function.php
14/var/www/html/discounts-n-coupons.com/vendor/ralouphie/getallheaders/src/getallheaders.php
15/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-ctype/bootstrap.php
16/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-ctype/bootstrap80.php
17/var/www/html/discounts-n-coupons.com/vendor/guzzlehttp/promises/src/functions_include.php
18/var/www/html/discounts-n-coupons.com/vendor/guzzlehttp/promises/src/functions.php
19/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-intl-grapheme/bootstrap.php
20/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-intl-normalizer/bootstrap.php
21/var/www/html/discounts-n-coupons.com/vendor/symfony/polyfill-intl-normalizer/bootstrap80.php
22/var/www/html/discounts-n-coupons.com/vendor/symfony/string/Resources/functions.php
23/var/www/html/discounts-n-coupons.com/vendor/guzzlehttp/guzzle/src/functions_include.php
24/var/www/html/discounts-n-coupons.com/vendor/guzzlehttp/guzzle/src/functions.php
25/var/www/html/discounts-n-coupons.com/vendor/symfony/var-dumper/Resources/functions/dump.php
26/var/www/html/discounts-n-coupons.com/vendor/phpseclib/phpseclib/phpseclib/bootstrap.php
27/var/www/html/discounts-n-coupons.com/vendor/google/apiclient-services/autoload.php
28/var/www/html/discounts-n-coupons.com/vendor/psy/psysh/src/functions.php
29/var/www/html/discounts-n-coupons.com/vendor/codeception/codeception/functions.php
30/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/aliases.php
31/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Client.php
32/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Service.php
33/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AccessToken/Revoke.php
34/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AccessToken/Verify.php
35/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Model.php
36/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Utils/UriTemplate.php
37/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AuthHandler/Guzzle6AuthHandler.php
38/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AuthHandler/Guzzle7AuthHandler.php
39/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AuthHandler/Guzzle5AuthHandler.php
40/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/AuthHandler/AuthHandlerFactory.php
41/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Http/Batch.php
42/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Http/MediaFileUpload.php
43/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Http/REST.php
44/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Task/Retryable.php
45/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Task/Exception.php
46/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Exception.php
47/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Task/Runner.php
48/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Collection.php
49/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Service/Exception.php
50/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Service/Resource.php
51/var/www/html/discounts-n-coupons.com/vendor/google/apiclient/src/Task/Composer.php
52/var/www/html/discounts-n-coupons.com/vendor/phalcon/dd/src/helper.php
53/var/www/html/discounts-n-coupons.com/vendor/clsystems/php-registry/src/Registry.php
54/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Config.php
55/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Asset.php
56/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/View/ViewBase.php
57/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Volt.php
58/var/www/html/discounts-n-coupons.com/src/app/Lib/CmsApplication.php
59/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Language.php
60/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/FileSystem.php
61/var/www/html/discounts-n-coupons.com/src/app/Language/de-DE/Locale.php
62/var/www/html/discounts-n-coupons.com/src/app/Language/en-GB/Locale.php
63/var/www/html/discounts-n-coupons.com/src/app/Language/nl-NL/Locale.php
64/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Uri.php
65/var/www/html/discounts-n-coupons.com/src/app/Language/de-DE/de-DE.php
66/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Event.php
67/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/Config.php
68/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/ModelBase.php
69/var/www/html/discounts-n-coupons.com/src/app/Plugin/Cms/SiteMap/SiteMap.php
70/var/www/html/discounts-n-coupons.com/src/app/Lib/Plugin.php
71/var/www/html/discounts-n-coupons.com/src/app/Plugin/Cms/SocialLogin/SocialLogin.php
72/var/www/html/discounts-n-coupons.com/src/app/Plugin/System/Backup/Backup.php
73/var/www/html/discounts-n-coupons.com/src/app/Plugin/System/Cms/Cms.php
74/var/www/html/discounts-n-coupons.com/src/app/Config/Router.php
75/var/www/html/discounts-n-coupons.com/src/app/Config/Router/Site.php
76/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Controller/DisplayController.php
77/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Controller/ControllerBase.php
78/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/User.php
79/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/State.php
80/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/User.php
81/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/Translation.php
82/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/UcmItem.php
83/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/UcmItem.php
84/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/Post.php
85/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/PostCategory.php
86/var/www/html/discounts-n-coupons.com/src/app/Lib/Mvc/Model/Nested.php
87/var/www/html/discounts-n-coupons.com/src/app/Lib/Helper/Text.php
Memory
Usage2097152