ErrorException {#13097 #severity: E_WARNING }
} //Get the current page text and href $items = new DOMXpath($dom); $dom = $items->query('//*[contains(@class, "breadcrumb_last")]'); $crumb[] = array('text' => $dom->item(0)->nodeValue, 'href' => trailingslashit(home_url($wp->request))); return $crumb; } return []; } public static function addBreadcrumb() { $ListItems = []; $Iterator = 1; foreach (self::get_crumb_array() as $crumb) { $ListItem = [ "@type" => "ListItem", "position" => $Iterator, "name" => $crumb["text"], "item" => $crumb["href"] public static function addBreadcrumbs() { self::addCustom([ "@context" => "http://schema.org", "@type" => "BreadcrumbList", "itemListElement" => self::addBreadcrumb(), ]); } public static function addBreadcrumb() { } protected function modifyContext(): array { SchemaGenerator::addSite(); SchemaGenerator::addBreadcrumbs(); SchemaGenerator::addOrganization(); SchemaGenerator::AddEvent([], $this); $theme = ThemeSettingsFactory::create(); protected function render(string $template, array $parameters): void { Timber::$dirname = ['../../twigs']; $context = Timber::context($parameters); $context = array_merge($context, $this->modifyContext()); Timber::render($template, $context); } protected function getHeader(): array { { $programsQuery = new ProgramsQuery(); $programsQuery->posts_per_page = 1000; $data = $this->getMappedData($programsQuery); $this->render('programPrint.twig', [ 'program_data' => $data, 'title' => __("Tisk programu", "BRILO_DOMAIN") ]); } return $vars;});add_action('template_redirect', function () { if (get_query_var('print_program')) { (new PrintProgramController())->indexAction(); exit; }}); // Avoid the array_slice() if possible. if ( 0 === $the_['accepted_args'] ) { $value = call_user_func( $the_['function'] ); } elseif ( $the_['accepted_args'] >= $num_args ) { $value = call_user_func_array( $the_['function'], $args ); } else { $value = call_user_func_array( $the_['function'], array_slice( $args, 0, $the_['accepted_args'] ) ); } } } while ( false !== next( $this->iterations[ $nesting_level ] ) ); * * @param array $args Parameters to pass to the callback functions. */ public function do_action( $args ) { $this->doing_action = true; $this->apply_filters( '', $args ); // If there are recursive calls to the current action, we haven't finished it until we get to the last one. if ( ! $this->nesting_level ) { $this->doing_action = false; } } elseif ( is_array( $arg[0] ) && 1 === count( $arg[0] ) && isset( $arg[0][0] ) && is_object( $arg[0][0] ) ) { // Backward compatibility for PHP4-style passing of `array( &$this )` as action `$arg`. $arg[0] = $arg[0][0]; } $wp_filter[ $hook_name ]->do_action( $arg ); array_pop( $wp_current_filter );}/** * the path to the new template you want to use. This will allow an alternative template to be used * without interfering with the WordPress loading process. * * @since 1.5.0 */ do_action( 'template_redirect' );}/** * Filters whether to allow 'HEAD' requests to generate content. * // 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';|
ErrorException
|
|---|
ErrorException:
Warning: Attempt to read property "nodeValue" on null
at /data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Components/SchemaGenerator/SchemaGenerator.php:561
at Components\SchemaGenerator\SchemaGenerator::get_crumb_array()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Components/SchemaGenerator/SchemaGenerator.php:172)
at Components\SchemaGenerator\SchemaGenerator::addBreadcrumb()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Components/SchemaGenerator/SchemaGenerator.php:164)
at Components\SchemaGenerator\SchemaGenerator::addBreadcrumbs()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Controller/ABaseController.php:79)
at Controller\ABaseController->modifyContext()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Controller/ABaseController.php:109)
at Controller\ABaseController->render()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Controller/PrintProgramController.php:21)
at Controller\PrintProgramController->indexAction()
(/data/htdocs/colours-dev/www/wp-content/themes/coloursofostrava/panda/Requires/Hooks.php:299)
at Utils\Cache::{closure}()
(/data/htdocs/colours-dev/www/wp-includes/class-wp-hook.php:341)
at WP_Hook->apply_filters()
(/data/htdocs/colours-dev/www/wp-includes/class-wp-hook.php:365)
at WP_Hook->do_action()
(/data/htdocs/colours-dev/www/wp-includes/plugin.php:522)
at do_action()
(/data/htdocs/colours-dev/www/wp-includes/template-loader.php:23)
at require_once('/data/htdocs/colours-dev/www/wp-includes/template-loader.php')
(/data/htdocs/colours-dev/www/wp-blog-header.php:19)
at require('/data/htdocs/colours-dev/www/wp-blog-header.php')
(/data/htdocs/colours-dev/www/index.php:17)
|