} public function getClickoutRiskhint($postId) : string { if ($this->brokerData['cta_risk'] != NULL) { $riskh = $this->brokerData['cta_risk']; } else { $riskh = get_field('warn_txt_individual_risk_warning', $postId); } return $riskh ?: ''; // flush out any stray output that might get out before an error occurs or // an exception is thrown. This prevents any partial views from leaking. try { $this->files->getRequire($path, $data); } catch (Throwable $e) { $this->handleViewException($e, $obLevel); } return ltrim(ob_get_clean()); } } // Once we have the path to the compiled file, we will evaluate the paths with // typical PHP just like any other templates. We also keep a stack of views // which have been rendered for right exception messages to be generated. $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data); array_pop($this->lastCompiled); return $results; } * * @return string */ protected function getContents() { return $this->engine->get($this->path, $this->gatherData()); } /** * Get the data bound to the view instance. * // clear out the sections for any separate views that may be rendered. $this->factory->incrementRender(); $this->factory->callComposer($this); $contents = $this->getContents(); // Once we've finished rendering the view, we'll decrement the render count // so that each sections get flushed out next time a view is created and // no old sections are staying around in the memory of an environment. $this->factory->decrementRender(); * @throws \Throwable */ public function render(callable $callback = null) { try { $contents = $this->renderContents(); $response = isset($callback) ? $callback($this, $contents) : null; // Once we have the contents of the view, we will flush the sections if we are // done rendering all views so that there is nothing left hanging over when <body <?php body_class('no-js'); ?>> <?php wp_body_open(); ?> <?php do_action('get_header'); ?> <div id="app"> <?php echo view(app('sage.view'), app('sage.data'))->render(); ?> </div> <?php do_action('get_footer'); ?> <?php wp_footer(); ?> </body> * * @param string $template The path of the template to include. */ $template = apply_filters( 'template_include', $template ); if ( $template ) { include $template; } elseif ( current_user_can( 'switch_themes' ) ) { $theme = wp_get_theme(); if ( $theme->errors() ) { wp_die( $theme->errors() ); } // Set up the WordPress query. wp(); // Load the theme template. require_once ABSPATH . WPINC . '/template-loader.php';} * @var bool */define( 'WP_USE_THEMES', true );/** Loads the WordPress Environment and Template */require __DIR__ . '/wp-blog-header.php'; } public function getClickoutRiskhint($postId) : string { if ($this->brokerData['cta_risk'] != NULL) { $riskh = $this->brokerData['cta_risk']; } else { $riskh = get_field('warn_txt_individual_risk_warning', $postId); } return $riskh ?: ''; * @throws \ErrorException */ public function handleError($level, $message, $file = '', $line = 0, $context = []) { try { parent::handleError($level, $message, $file, $line, $context); } catch (Throwable $e) { if (! apply_filters('acorn/throw_error_exception', true, $e)) { return false; } } public function getClickoutRiskhint($postId) : string { if ($this->brokerData['cta_risk'] != NULL) { $riskh = $this->brokerData['cta_risk']; } else { $riskh = get_field('warn_txt_individual_risk_warning', $postId); } return $riskh ?: ''; $this->rankingLabelData = $this->getRankingLabelData($ranking); $this->guides = $this->getRelatedGuides($postId); $this->brokerData = $this->getBrokerVerticalData($postId); $this->clickOutLink = $this->setClickOutLink(); $this->clickOutText = $this->setClickOutText(); $this->clickoutRiskhint = $this->getClickoutRiskhint($postId); $this->tradefieldslug = $this->getTradefieldSlug(); // $this->trade = $this->brokerData; $this->mfees = $this->getMfees(); throw $e; } array_pop($this->buildStack); return $reflector->newInstanceArgs($instances); } /** * Resolve all of the dependencies from the ReflectionParameters. * // We're ready to instantiate an instance of the concrete type registered for // the binding. This will instantiate the types, as well as resolve any of // its "nested" dependencies recursively until all have gotten resolved. if ($this->isBuildable($concrete, $abstract)) { $object = $this->build($concrete); } else { $object = $this->make($concrete); } // If we defined any extenders for this type, we'll need to spin through them */ protected function resolve($abstract, $parameters = [], $raiseEvents = true) { $this->loadDeferredProviderIfNeeded($abstract = $this->getAlias($abstract)); return parent::resolve($abstract, $parameters, $raiseEvents); } /** * Load the deferred provider if the given type is a deferred service and the instance has not been loaded. * * * @throws \Illuminate\Contracts\Container\BindingResolutionException */ public function make($abstract, array $parameters = []) { return $this->resolve($abstract, $parameters); } /** * {@inheritdoc} * */ public function make($abstract, array $parameters = []) { $this->loadDeferredProviderIfNeeded($abstract = $this->getAlias($abstract)); return parent::make($abstract, $parameters); } /** * Resolve the given type from the container. * <div class="at-compare mt-12 mb-10 border-4 border-solid border-gray-border border-b-0 rounded-tr-[10px] lg:rounded-[10px] "> <?php if (empty($query)) : ?><?php global $wp_query; ?><?php $query = $wp_query; ?><?php endif; ?><?php if ($query->have_posts()) : ?><?php while ($query->have_posts()) : $query->the_post(); ?> <?php if (isset($component)) { $__componentOriginal32630f1cc9b1df281059bb481f185eb4360446ea = $component; } ?><?php $component = $__env->getContainer()->make(App\View\Components\CompareCard::class, ['postId' => get_the_ID(),'ranking' => $i]); ?><?php $component->withName('compare-card'); ?><?php if ($component->shouldRender()): ?><?php $__env->startComponent($component->resolveView(), $component->data()); ?><?php $component->withAttributes(['hasRankingImage' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($i <= 3),'parentPostId' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($mainPostId)]); ?><?php echo $__env->renderComponent(); ?> $__data = $data; return (static function () use ($__path, $__data) { extract($__data, EXTR_SKIP); return require $__path; })(); } throw new FileNotFoundException("File does not exist at path {$path}."); } return (static function () use ($__path, $__data) { extract($__data, EXTR_SKIP); return require $__path; })(); } throw new FileNotFoundException("File does not exist at path {$path}."); } // We'll evaluate the contents of the view inside a try/catch block so we can // flush out any stray output that might get out before an error occurs or // an exception is thrown. This prevents any partial views from leaking. try { $this->files->getRequire($path, $data); } catch (Throwable $e) { $this->handleViewException($e, $obLevel); } return ltrim(ob_get_clean()); } // Once we have the path to the compiled file, we will evaluate the paths with // typical PHP just like any other templates. We also keep a stack of views // which have been rendered for right exception messages to be generated. $results = $this->evaluatePath($this->compiler->getCompiledPath($path), $data); array_pop($this->lastCompiled); return $results; } * * @return string */ protected function getContents() { return $this->engine->get($this->path, $this->gatherData()); } /** * Get the data bound to the view instance. * // clear out the sections for any separate views that may be rendered. $this->factory->incrementRender(); $this->factory->callComposer($this); $contents = $this->getContents(); // Once we've finished rendering the view, we'll decrement the render count // so that each sections get flushed out next time a view is created and // no old sections are staying around in the memory of an environment. $this->factory->decrementRender(); * @throws \Throwable */ public function render(callable $callback = null) { try { $contents = $this->renderContents(); $response = isset($callback) ? $callback($this, $contents) : null; // Once we have the contents of the view, we will flush the sections if we are // done rendering all views so that there is nothing left hanging over when <body <?php body_class('no-js'); ?>> <?php wp_body_open(); ?> <?php do_action('get_header'); ?> <div id="app"> <?php echo view(app('sage.view'), app('sage.data'))->render(); ?> </div> <?php do_action('get_footer'); ?> <?php wp_footer(); ?> </body> * * @param string $template The path of the template to include. */ $template = apply_filters( 'template_include', $template ); if ( $template ) { include $template; } elseif ( current_user_can( 'switch_themes' ) ) { $theme = wp_get_theme(); if ( $theme->errors() ) { wp_die( $theme->errors() ); } // Set up the WordPress query. wp(); // Load the theme template. require_once ABSPATH . WPINC . '/template-loader.php';} * @var bool */define( 'WP_USE_THEMES', true );/** Loads the WordPress Environment and Template */require __DIR__ . '/wp-blog-header.php';|
[2/2]
ViewException
|
|---|
Illuminate\View\ViewException:
Undefined array key "cta_risk" (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/archive-broker.blade.php)
at /var/www/html/wp-content/themes/asktraders2022/app/View/Components/CompareCard.php:102
at Illuminate\View\Engines\CompilerEngine->handleViewException()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/Engines/PhpEngine.php:60)
at Illuminate\View\Engines\PhpEngine->evaluatePath()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/Engines/CompilerEngine.php:61)
at Illuminate\View\Engines\CompilerEngine->get()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:139)
at Illuminate\View\View->getContents()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:122)
at Illuminate\View\View->renderContents()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:91)
at Illuminate\View\View->render()
(/var/www/html/wp-content/themes/asktraders2022/index.php:15)
at include('/var/www/html/wp-content/themes/asktraders2022/index.php')
(/var/www/html/wp-includes/template-loader.php:106)
at require_once('/var/www/html/wp-includes/template-loader.php')
(/var/www/html/wp-blog-header.php:19)
at require('/var/www/html/wp-blog-header.php')
(/var/www/html/index.php:17)
|
|
[1/2]
ErrorException
|
|---|
ErrorException:
Undefined array key "cta_risk"
at /var/www/html/wp-content/themes/asktraders2022/app/View/Components/CompareCard.php:102
at Illuminate\Foundation\Bootstrap\HandleExceptions->handleError()
(/var/www/html/wp-content/themes/asktraders2022/vendor/roots/acorn/src/Roots/Acorn/Bootstrap/HandleExceptions.php:55)
at Roots\Acorn\Bootstrap\HandleExceptions->handleError()
(/var/www/html/wp-content/themes/asktraders2022/app/View/Components/CompareCard.php:102)
at App\View\Components\CompareCard->getClickoutRiskhint()
(/var/www/html/wp-content/themes/asktraders2022/app/View/Components/CompareCard.php:44)
at App\View\Components\CompareCard->__construct()
at ReflectionClass->newInstanceArgs()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/container/Container.php:917)
at Illuminate\Container\Container->build()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/container/Container.php:758)
at Illuminate\Container\Container->resolve()
(/var/www/html/wp-content/themes/asktraders2022/vendor/roots/acorn/src/Illuminate/Foundation/Application.php:851)
at Illuminate\Foundation\Application->resolve()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/container/Container.php:694)
at Illuminate\Container\Container->make()
(/var/www/html/wp-content/themes/asktraders2022/vendor/roots/acorn/src/Illuminate/Foundation/Application.php:836)
at Illuminate\Foundation\Application->make()
(/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/9bea35ac2c02b18e239bef18237ca6183af34811.php:35)
at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/9bea35ac2c02b18e239bef18237ca6183af34811.php')
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/filesystem/Filesystem.php:107)
at Illuminate\Filesystem\Filesystem::Illuminate\Filesystem\{closure}()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/filesystem/Filesystem.php:108)
at Illuminate\Filesystem\Filesystem->getRequire()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/Engines/PhpEngine.php:58)
at Illuminate\View\Engines\PhpEngine->evaluatePath()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/Engines/CompilerEngine.php:61)
at Illuminate\View\Engines\CompilerEngine->get()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:139)
at Illuminate\View\View->getContents()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:122)
at Illuminate\View\View->renderContents()
(/var/www/html/wp-content/themes/asktraders2022/vendor/illuminate/view/View.php:91)
at Illuminate\View\View->render()
(/var/www/html/wp-content/themes/asktraders2022/index.php:15)
at include('/var/www/html/wp-content/themes/asktraders2022/index.php')
(/var/www/html/wp-includes/template-loader.php:106)
at require_once('/var/www/html/wp-includes/template-loader.php')
(/var/www/html/wp-blog-header.php:19)
at require('/var/www/html/wp-blog-header.php')
(/var/www/html/index.php:17)
|