Symfony Exception

ValueError ViewException ViewException ViewException

HTTP 500 Internal Server Error

DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

Exceptions 4

Illuminate\View\ ViewException

  1.             if(get_field('show_table_of_contents')){
  2.                 if (!$html) return $html;
  3.                 $new_html=preg_replace("/(<aside(\n|.)*?<\/aside>)/i"""$html);
  4.                 $dom = new DOMDocument();
  5.                 libxml_use_internal_errors(true);
  6.                 $dom->loadHTML(mb_convert_encoding($new_html'HTML-ENTITIES''UTF-8'));
  7.                 libxml_clear_errors();
  8.                 $toc.=toc_builder($dom'toc-sticky','multiCollapse1');
  9.                 $toc.=toc_builder($dom'toc-sticky-list','multiCollapse2');
  10.                 
  11.                 //$dom->getElementsByTagName('h2')[0]->parentNode->insertBefore($toc, $dom->getElementsByTagName('h2')[0]);
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path$data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e$obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.   <body <?php body_class('no-js'); ?>>
  2.     <?php wp_body_open(); ?>
  3.     <?php do_action('get_header'); ?>
  4.     <div id="app">
  5.       <?php echo view(app('sage.view'), app('sage.data'))->render(); ?>
  6.     </div>
  7.     <?php do_action('get_footer'); ?>
  8.     <?php wp_footer(); ?>
  9.   </body>
include('/var/www/html/wp-content/themes/asktraders2022/index.php') in /var/www/html/wp-includes/template-loader.php (line 106)
  1.      *
  2.      * @param string $template The path of the template to include.
  3.      */
  4.     $template apply_filters'template_include'$template );
  5.     if ( $template ) {
  6.         include $template;
  7.     } elseif ( current_user_can'switch_themes' ) ) {
  8.         $theme wp_get_theme();
  9.         if ( $theme->errors() ) {
  10.             wp_die$theme->errors() );
  11.         }
require_once('/var/www/html/wp-includes/template-loader.php') in /var/www/html/wp-blog-header.php (line 19)
  1.     // Set up the WordPress query.
  2.     wp();
  3.     // Load the theme template.
  4.     require_once ABSPATH WPINC '/template-loader.php';
  5. }
require('/var/www/html/wp-blog-header.php') in /var/www/html/index.php (line 17)
  1.  * @var bool
  2.  */
  3. define'WP_USE_THEMES'true );
  4. /** Loads the WordPress Environment and Template */
  5. require __DIR__ '/wp-blog-header.php';

Illuminate\View\ ViewException

DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

  1.             if(get_field('show_table_of_contents')){
  2.                 if (!$html) return $html;
  3.                 $new_html=preg_replace("/(<aside(\n|.)*?<\/aside>)/i"""$html);
  4.                 $dom = new DOMDocument();
  5.                 libxml_use_internal_errors(true);
  6.                 $dom->loadHTML(mb_convert_encoding($new_html'HTML-ENTITIES''UTF-8'));
  7.                 libxml_clear_errors();
  8.                 $toc.=toc_builder($dom'toc-sticky','multiCollapse1');
  9.                 $toc.=toc_builder($dom'toc-sticky-list','multiCollapse2');
  10.                 
  11.                 //$dom->getElementsByTagName('h2')[0]->parentNode->insertBefore($toc, $dom->getElementsByTagName('h2')[0]);
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path$data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e$obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.  */
  2. ?>
  3. <?php echo $__env->make('single'\Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?><?php /**PATH /var/www/html/wp-content/themes/asktraders2022/resources/views/single-default.blade.php ENDPATH**/ ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.   <body <?php body_class('no-js'); ?>>
  2.     <?php wp_body_open(); ?>
  3.     <?php do_action('get_header'); ?>
  4.     <div id="app">
  5.       <?php echo view(app('sage.view'), app('sage.data'))->render(); ?>
  6.     </div>
  7.     <?php do_action('get_footer'); ?>
  8.     <?php wp_footer(); ?>
  9.   </body>
include('/var/www/html/wp-content/themes/asktraders2022/index.php') in /var/www/html/wp-includes/template-loader.php (line 106)
  1.      *
  2.      * @param string $template The path of the template to include.
  3.      */
  4.     $template apply_filters'template_include'$template );
  5.     if ( $template ) {
  6.         include $template;
  7.     } elseif ( current_user_can'switch_themes' ) ) {
  8.         $theme wp_get_theme();
  9.         if ( $theme->errors() ) {
  10.             wp_die$theme->errors() );
  11.         }
require_once('/var/www/html/wp-includes/template-loader.php') in /var/www/html/wp-blog-header.php (line 19)
  1.     // Set up the WordPress query.
  2.     wp();
  3.     // Load the theme template.
  4.     require_once ABSPATH WPINC '/template-loader.php';
  5. }
require('/var/www/html/wp-blog-header.php') in /var/www/html/index.php (line 17)
  1.  * @var bool
  2.  */
  3. define'WP_USE_THEMES'true );
  4. /** Loads the WordPress Environment and Template */
  5. require __DIR__ '/wp-blog-header.php';

Illuminate\View\ ViewException

DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

  1.             if(get_field('show_table_of_contents')){
  2.                 if (!$html) return $html;
  3.                 $new_html=preg_replace("/(<aside(\n|.)*?<\/aside>)/i"""$html);
  4.                 $dom = new DOMDocument();
  5.                 libxml_use_internal_errors(true);
  6.                 $dom->loadHTML(mb_convert_encoding($new_html'HTML-ENTITIES''UTF-8'));
  7.                 libxml_clear_errors();
  8.                 $toc.=toc_builder($dom'toc-sticky','multiCollapse1');
  9.                 $toc.=toc_builder($dom'toc-sticky-list','multiCollapse2');
  10.                 
  11.                 //$dom->getElementsByTagName('h2')[0]->parentNode->insertBefore($toc, $dom->getElementsByTagName('h2')[0]);
  1.         // flush out any stray output that might get out before an error occurs or
  2.         // an exception is thrown. This prevents any partial views from leaking.
  3.         try {
  4.             $this->files->getRequire($path$data);
  5.         } catch (Throwable $e) {
  6.             $this->handleViewException($e$obLevel);
  7.         }
  8.         return ltrim(ob_get_clean());
  9.     }
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1. <?php $__env->startSection('content'); ?>
  2.     <?php while(have_posts()): ?>
  3.         <?php (the_post()); ?>
  4.         <?php echo $__env->first(['partials.content-single-' get_post_type(), 'partials.content-single'], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?>
  5.     <?php endwhile; ?>
  6. <?php $__env->stopSection(); ?>
  7. <?php $__env->startSection('sidebar'); ?>
  8.     <div class="hidden"></div>
  9. <?php $__env->stopSection(); ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.  */
  2. ?>
  3. <?php echo $__env->make('single'\Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?><?php /**PATH /var/www/html/wp-content/themes/asktraders2022/resources/views/single-default.blade.php ENDPATH**/ ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.   <body <?php body_class('no-js'); ?>>
  2.     <?php wp_body_open(); ?>
  3.     <?php do_action('get_header'); ?>
  4.     <div id="app">
  5.       <?php echo view(app('sage.view'), app('sage.data'))->render(); ?>
  6.     </div>
  7.     <?php do_action('get_footer'); ?>
  8.     <?php wp_footer(); ?>
  9.   </body>
include('/var/www/html/wp-content/themes/asktraders2022/index.php') in /var/www/html/wp-includes/template-loader.php (line 106)
  1.      *
  2.      * @param string $template The path of the template to include.
  3.      */
  4.     $template apply_filters'template_include'$template );
  5.     if ( $template ) {
  6.         include $template;
  7.     } elseif ( current_user_can'switch_themes' ) ) {
  8.         $theme wp_get_theme();
  9.         if ( $theme->errors() ) {
  10.             wp_die$theme->errors() );
  11.         }
require_once('/var/www/html/wp-includes/template-loader.php') in /var/www/html/wp-blog-header.php (line 19)
  1.     // Set up the WordPress query.
  2.     wp();
  3.     // Load the theme template.
  4.     require_once ABSPATH WPINC '/template-loader.php';
  5. }
require('/var/www/html/wp-blog-header.php') in /var/www/html/index.php (line 17)
  1.  * @var bool
  2.  */
  3. define'WP_USE_THEMES'true );
  4. /** Loads the WordPress Environment and Template */
  5. require __DIR__ '/wp-blog-header.php';

ValueError

DOMDocument::loadHTML(): Argument #1 ($source) must not be empty

  1.             if(get_field('show_table_of_contents')){
  2.                 if (!$html) return $html;
  3.                 $new_html=preg_replace("/(<aside(\n|.)*?<\/aside>)/i"""$html);
  4.                 $dom = new DOMDocument();
  5.                 libxml_use_internal_errors(true);
  6.                 $dom->loadHTML(mb_convert_encoding($new_html'HTML-ENTITIES''UTF-8'));
  7.                 libxml_clear_errors();
  8.                 $toc.=toc_builder($dom'toc-sticky','multiCollapse1');
  9.                 $toc.=toc_builder($dom'toc-sticky-list','multiCollapse2');
  10.                 
  11.                 //$dom->getElementsByTagName('h2')[0]->parentNode->insertBefore($toc, $dom->getElementsByTagName('h2')[0]);
  1.             if(get_field('show_table_of_contents')){
  2.                 if (!$html) return $html;
  3.                 $new_html=preg_replace("/(<aside(\n|.)*?<\/aside>)/i"""$html);
  4.                 $dom = new DOMDocument();
  5.                 libxml_use_internal_errors(true);
  6.                 $dom->loadHTML(mb_convert_encoding($new_html'HTML-ENTITIES''UTF-8'));
  7.                 libxml_clear_errors();
  8.                 $toc.=toc_builder($dom'toc-sticky','multiCollapse1');
  9.                 $toc.=toc_builder($dom'toc-sticky-list','multiCollapse2');
  10.                 
  11.                 //$dom->getElementsByTagName('h2')[0]->parentNode->insertBefore($toc, $dom->getElementsByTagName('h2')[0]);
  1.                 // Avoid the array_slice() if possible.
  2.                 if ( === $the_['accepted_args'] ) {
  3.                     $value call_user_func$the_['function'] );
  4.                 } elseif ( $the_['accepted_args'] >= $num_args ) {
  5.                     $value call_user_func_array$the_['function'], $args );
  6.                 } else {
  7.                     $value call_user_func_array$the_['function'], array_slice$args0$the_['accepted_args'] ) );
  8.                 }
  9.             }
  10.         } while ( false !== next$this->iterations$nesting_level ] ) );
WP_Hook->apply_filters() in /var/www/html/wp-includes/plugin.php (line 205)
  1.     }
  2.     // Pass the value to WP_Hook.
  3.     array_unshift$args$value );
  4.     $filtered $wp_filter$hook_name ]->apply_filters$value$args );
  5.     array_pop$wp_current_filter );
  6.     return $filtered;
  7. }
apply_filters() in /var/www/html/wp-includes/post-template.php (line 256)
  1.      *
  2.      * @since 0.71
  3.      *
  4.      * @param string $content Content of the current post.
  5.      */
  6.     $content apply_filters'the_content'$content );
  7.     $content str_replace']]>'']]&gt;'$content );
  8.     echo $content;
  9. }
  10. /**
  1.     </header>
  2.     <?php echo $__env->make('partials/entry-meta'\Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?>
  3.     <!-- Lead -->
  4.     <div class="container my-3">
  5.         <div class="entry-content">
  6.             <?php echo the_content(); ?>
  7.         </div>
  8.     </div>
  9.     <?php if (isset($component)) { $__componentOriginal166f2dbf031bce43c5fa613a7aa7a5026579cb0e $component; } ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1. <?php $__env->startSection('content'); ?>
  2.     <?php while(have_posts()): ?>
  3.         <?php (the_post()); ?>
  4.         <?php echo $__env->first(['partials.content-single-' get_post_type(), 'partials.content-single'], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?>
  5.     <?php endwhile; ?>
  6. <?php $__env->stopSection(); ?>
  7. <?php $__env->startSection('sidebar'); ?>
  8.     <div class="hidden"></div>
  9. <?php $__env->stopSection(); ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.  */
  2. ?>
  3. <?php echo $__env->make('single'\Illuminate\Support\Arr::except(get_defined_vars(), ['__data''__path']))->render(); ?><?php /**PATH /var/www/html/wp-content/themes/asktraders2022/resources/views/single-default.blade.php ENDPATH**/ ?>
  1.             $__data $data;
  2.             return (static function () use ($__path$__data) {
  3.                 extract($__dataEXTR_SKIP);
  4.                 return require $__path;
  5.             })();
  6.         }
  7.         throw new FileNotFoundException("File does not exist at path {$path}.");
  8.     }
  1.             return (static function () use ($__path$__data) {
  2.                 extract($__dataEXTR_SKIP);
  3.                 return require $__path;
  4.             })();
  5.         }
  6.         throw new FileNotFoundException("File does not exist at path {$path}.");
  7.     }
  1.         // We'll evaluate the contents of the view inside a try/catch block so we can
  2.         // flush out any stray output that might get out before an error occurs or
  3.         // an exception is thrown. This prevents any partial views from leaking.
  4.         try {
  5.             $this->files->getRequire($path$data);
  6.         } catch (Throwable $e) {
  7.             $this->handleViewException($e$obLevel);
  8.         }
  9.         return ltrim(ob_get_clean());
  1.         }
  2.         // Once we have the path to the compiled file, we will evaluate the paths with
  3.         // typical PHP just like any other templates. We also keep a stack of views
  4.         // which have been rendered for right exception messages to be generated.
  5.         $results $this->evaluatePath($this->compiler->getCompiledPath($path), $data);
  6.         array_pop($this->lastCompiled);
  7.         return $results;
  8.     }
  1.      *
  2.      * @return string
  3.      */
  4.     protected function getContents()
  5.     {
  6.         return $this->engine->get($this->path$this->gatherData());
  7.     }
  8.     /**
  9.      * Get the data bound to the view instance.
  10.      *
  1.         // clear out the sections for any separate views that may be rendered.
  2.         $this->factory->incrementRender();
  3.         $this->factory->callComposer($this);
  4.         $contents $this->getContents();
  5.         // Once we've finished rendering the view, we'll decrement the render count
  6.         // so that each sections get flushed out next time a view is created and
  7.         // no old sections are staying around in the memory of an environment.
  8.         $this->factory->decrementRender();
  1.      * @throws \Throwable
  2.      */
  3.     public function render(callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.   <body <?php body_class('no-js'); ?>>
  2.     <?php wp_body_open(); ?>
  3.     <?php do_action('get_header'); ?>
  4.     <div id="app">
  5.       <?php echo view(app('sage.view'), app('sage.data'))->render(); ?>
  6.     </div>
  7.     <?php do_action('get_footer'); ?>
  8.     <?php wp_footer(); ?>
  9.   </body>
include('/var/www/html/wp-content/themes/asktraders2022/index.php') in /var/www/html/wp-includes/template-loader.php (line 106)
  1.      *
  2.      * @param string $template The path of the template to include.
  3.      */
  4.     $template apply_filters'template_include'$template );
  5.     if ( $template ) {
  6.         include $template;
  7.     } elseif ( current_user_can'switch_themes' ) ) {
  8.         $theme wp_get_theme();
  9.         if ( $theme->errors() ) {
  10.             wp_die$theme->errors() );
  11.         }
require_once('/var/www/html/wp-includes/template-loader.php') in /var/www/html/wp-blog-header.php (line 19)
  1.     // Set up the WordPress query.
  2.     wp();
  3.     // Load the theme template.
  4.     require_once ABSPATH WPINC '/template-loader.php';
  5. }
require('/var/www/html/wp-blog-header.php') in /var/www/html/index.php (line 17)
  1.  * @var bool
  2.  */
  3. define'WP_USE_THEMES'true );
  4. /** Loads the WordPress Environment and Template */
  5. require __DIR__ '/wp-blog-header.php';

Stack Traces 4

[4/4] ViewException
Illuminate\View\ViewException:
DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

  at /var/www/html/wp-content/themes/asktraders2022/app/View/legacy_functions/functions.php:599
  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)                
[3/4] ViewException
Illuminate\View\ViewException:
DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php) (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

  at /var/www/html/wp-content/themes/asktraders2022/app/View/legacy_functions/functions.php:599
  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/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.php:10)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.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)                
[2/4] ViewException
Illuminate\View\ViewException:
DOMDocument::loadHTML(): Argument #1 ($source) must not be empty (View: /var/www/html/wp-content/themes/asktraders2022/resources/views/partials/content-single.blade.php)

  at /var/www/html/wp-content/themes/asktraders2022/app/View/legacy_functions/functions.php:599
  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/storage/framework/views/e59e8f17279613079b4b9beb1b479c2fc9a1de61.php:4)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/e59e8f17279613079b4b9beb1b479c2fc9a1de61.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/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.php:10)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.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)                
[1/4] ValueError
ValueError:
DOMDocument::loadHTML(): Argument #1 ($source) must not be empty

  at /var/www/html/wp-content/themes/asktraders2022/app/View/legacy_functions/functions.php:599
  at DOMDocument->loadHTML()
     (/var/www/html/wp-content/themes/asktraders2022/app/View/legacy_functions/functions.php:599)
  at create_toc()
     (/var/www/html/wp-includes/class-wp-hook.php:324)
  at WP_Hook->apply_filters()
     (/var/www/html/wp-includes/plugin.php:205)
  at apply_filters()
     (/var/www/html/wp-includes/post-template.php:256)
  at the_content()
     (/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/e649611e37dde612940f19a1d2129630cab2bcd5.php:20)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/e649611e37dde612940f19a1d2129630cab2bcd5.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/storage/framework/views/e59e8f17279613079b4b9beb1b479c2fc9a1de61.php:4)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/e59e8f17279613079b4b9beb1b479c2fc9a1de61.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/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.php:10)
  at require('/var/www/html/wp-content/themes/asktraders2022/storage/framework/views/61c60b2b1b142c22e74ef650aee57b798e22b9ca.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)