Whoops \ Exception \ ErrorException (E_WARNING)
Undefined variable $result Whoops\Exception\ErrorException thrown with message "Undefined variable $result" Stacktrace: #12 Whoops\Exception\ErrorException in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php:33 #11 Whoops\Run:handleError in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php:33 #10 h_page_bg_id in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php:45 #9 h_page_bg in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/views/site/blog/archive/archive.php:5 #8 require in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Helpers/misc.php:154 #7 h_perform in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Views/View.php:262 #6 Modules\Views\View:render in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Views/View.php:285 #5 Modules\Views\View:print in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php:15 #4 {closure:/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php:5} in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Helpers/misc.php:120 #3 iife in /home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php:5 #2 include in /home/farmaboo/domains/underbodyguards.com/public_html/wp-includes/template-loader.php:132 #1 require_once in /home/farmaboo/domains/underbodyguards.com/public_html/wp-blog-header.php:19 #0 require in /home/farmaboo/domains/underbodyguards.com/public_html/index.php:17
Stack frames (13)
12
Whoops\Exception\ErrorException
/wp-content/themes/wph/includes/helpers.php:33
11
Whoops\Run handleError
/wp-content/themes/wph/includes/helpers.php:33
10
h_page_bg_id
/wp-content/themes/wph/includes/helpers.php:45
9
h_page_bg
/wp-content/themes/wph/views/site/blog/archive/archive.php:5
8
require
/wp-content/themes/wph/modules/Helpers/misc.php:154
7
h_perform
/wp-content/themes/wph/modules/Views/View.php:262
6
Modules\Views\View render
/wp-content/themes/wph/modules/Views/View.php:285
5
Modules\Views\View print
/wp-content/themes/wph/archive.php:15
4
{closure:/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php:5}
/wp-content/themes/wph/modules/Helpers/misc.php:120
3
iife
/wp-content/themes/wph/archive.php:5
2
include
/wp-includes/template-loader.php:132
1
require_once
/wp-blog-header.php:19
0
require
/index.php:17
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php
        return get_the_title(get_queried_object());
    } elseif (is_archive()) {
        return get_the_archive_title();
    } elseif (is_home()) {
        return get_the_title(wph_blog_page_id());
    } else {
        return wp_title();
    }
}
 
function h_page_bg_id()
{
    if (is_singular()) {
        $result = ah_field('background', get_queried_object_id());
    } elseif (is_home()) {
        $result = ah_field('background', wph_blog_page_id());
    } elseif (is_product_category()) {
        $result = ah_field('background', get_queried_object());
    }
    if (is_empty($result)) {
        $result = ah_option('info.image');
    }
    return $result;
}
 
/**
 * @param array|string $attrOrClass
 * @return string|null
 */
function h_page_bg($attrOrClass = [])
{
    return wph_image(h_page_bg_id(), $attrOrClass);
}
 
function h_format_copyright($input)
{
    if (is_empty($input)) {
        return '';
    }
    $replace = [
Arguments
  1. "Undefined variable $result"
    
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php
        return get_the_title(get_queried_object());
    } elseif (is_archive()) {
        return get_the_archive_title();
    } elseif (is_home()) {
        return get_the_title(wph_blog_page_id());
    } else {
        return wp_title();
    }
}
 
function h_page_bg_id()
{
    if (is_singular()) {
        $result = ah_field('background', get_queried_object_id());
    } elseif (is_home()) {
        $result = ah_field('background', wph_blog_page_id());
    } elseif (is_product_category()) {
        $result = ah_field('background', get_queried_object());
    }
    if (is_empty($result)) {
        $result = ah_option('info.image');
    }
    return $result;
}
 
/**
 * @param array|string $attrOrClass
 * @return string|null
 */
function h_page_bg($attrOrClass = [])
{
    return wph_image(h_page_bg_id(), $attrOrClass);
}
 
function h_format_copyright($input)
{
    if (is_empty($input)) {
        return '';
    }
    $replace = [
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/includes/helpers.php
    if (is_singular()) {
        $result = ah_field('background', get_queried_object_id());
    } elseif (is_home()) {
        $result = ah_field('background', wph_blog_page_id());
    } elseif (is_product_category()) {
        $result = ah_field('background', get_queried_object());
    }
    if (is_empty($result)) {
        $result = ah_option('info.image');
    }
    return $result;
}
 
/**
 * @param array|string $attrOrClass
 * @return string|null
 */
function h_page_bg($attrOrClass = [])
{
    return wph_image(h_page_bg_id(), $attrOrClass);
}
 
function h_format_copyright($input)
{
    if (is_empty($input)) {
        return '';
    }
    $replace = [
        '{year}' => date('Y'),
        '{domain}' => parse_url(site_url(), PHP_URL_HOST),
    ];
    return str_replace(
        array_keys($replace),
        array_values($replace),
        $input,
    );
}
 
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/views/site/blog/archive/archive.php
<?php
vh_class('blogArchive');
?>
<div class="baInfo">
    <?= h_page_bg('baInfo-bg') ?>
    <div class="baInfo-header">
        <?= view('site/layout/header') ?>
    </div>
    <div class="baInfo-main">
        <div class="baInfo-container">
            <h1 class="baInfo-title">
                <?= get_the_archive_title(); ?>
            </h1>
        </div>
    </div>
</div>
<main class="baMain">
    <?= view('../cards')->data(compact('query')) ?>
</main>
 
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Helpers/misc.php
    return $result;
}
 
/**
 * @param string $path
 * @param array $data
 * @param bool $optional
 * @return mixed
 * @noinspection PhpDocSignatureInspection
 */
function h_perform()
{
    if (func_num_args() !== 3) {
        throw new InvalidArgumentException('Invalid argument number.');
    }
    extract(func_get_arg(1));
    if (func_get_arg(2)) {
        return include func_get_arg(0);
    } else {
        return require func_get_arg(0);
    }
}
 
/**
 * @param callable $callback
 * @return string|null
 */
function h_render($callback)
{
    ob_start();
    $callback();
    $result = ob_get_clean();
    if (is_empty($result)) {
        $result = null;
    }
    return $result;
}
 
/**
 * @param object|array $data
Arguments
  1. "/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/views/site/blog/archive/archive.php"
    
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Views/View.php
     * @param string $content
     * @return string
     */
    private function renderLayout($content)
    {
        $layout = $this->layout instanceof self
            ? $this->layout
            : view($this->layout, null);
        $layout->data('content', $content);
        return $layout->render();
    }

    /**
     * @return string
     */
    public function render()
    {
        ViewState::beforeRendering($this);
        ob_start();
        $result = h_perform($this->fullPath, $this->data, false);
        $isEmpty = $result === 0;
        $content = ob_get_clean();
        if (!$isEmpty) {
            if (!is_string($content)) {
                $content = '';
            }
            $content = trim($content);
            if ($this->isPlain) {
                $result = $content;
            } else {
                $this->setAttributes();
                $result = $this->renderElement($content);
            }
        } else {
            $result = '';
        }
        ViewState::afterRendering();
        return $this->layout ? $this->renderLayout($result) : $result;
    }

/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Views/View.php
            if (!is_string($content)) {
                $content = '';
            }
            $content = trim($content);
            if ($this->isPlain) {
                $result = $content;
            } else {
                $this->setAttributes();
                $result = $this->renderElement($content);
            }
        } else {
            $result = '';
        }
        ViewState::afterRendering();
        return $this->layout ? $this->renderLayout($result) : $result;
    }

    public function print()
    {
        echo $this->render();
    }

    public function __toString()
    {
        return $this->render();
    }
}
 
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php
<?php

defined('WPH') or exit;

iife(function () {
    if (eh_has_location('archive')) {
        view('site/page/theme')
            ->data('content', eh_location('archive'))
            ->defaultLayout()
            ->print();
    } else {
        view('site/blog/archive')
            ->defaultLayout()
            ->data(['query' => wph_the_query()])
            ->print();
    }
});
 
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/modules/Helpers/misc.php
}
 
/**
 * @param string|object $class
 * @return string
 */
function class_basename($class)
{
    $class = is_object($class) ? get_class($class) : $class;
    $class = str_replace('\\', '/', $class);
    return basename($class);
}
 
/**
 * @param Closure $fn
 * @return mixed
 */
function iife(Closure $fn)
{
    return $fn();
}
 
/**
 * @param string $base
 * @param string ...$parts
 * @return string
 */
function h_build_path($base, ...$parts)
{
    $result = $base;
    foreach ($parts as $part) {
        $part = trim($part, '/\\');
        $result .= '/' . $part;
    }
    return $result;
}
 
/**
 * @param string $path
 * @param array $data
/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php
<?php

defined('WPH') or exit;

iife(function () {
    if (eh_has_location('archive')) {
        view('site/page/theme')
            ->data('content', eh_location('archive'))
            ->defaultLayout()
            ->print();
    } else {
        view('site/blog/archive')
            ->defaultLayout()
            ->data(['query' => wph_the_query()])
            ->print();
    }
});
 
/home/farmaboo/domains/underbodyguards.com/public_html/wp-includes/template-loader.php
     */
    $template   = apply_filters( 'template_include', $template );
    $is_stringy = is_string( $template ) || ( is_object( $template ) && method_exists( $template, '__toString' ) );
    $template   = $is_stringy ? realpath( (string) $template ) : null;
    if (
        is_string( $template ) &&
        ( str_ends_with( $template, '.php' ) || str_ends_with( $template, '.html' ) ) &&
        is_file( $template ) &&
        is_readable( $template )
    ) {
        /**
         * Fires immediately before including the template.
         *
         * @since 6.9.0
         *
         * @param string $template The path of the template about to be included.
         */
        do_action( 'wp_before_include_template', $template );
 
        include $template;
    } elseif ( current_user_can( 'switch_themes' ) ) {
        $theme = wp_get_theme();
        if ( $theme->errors() ) {
            wp_die( $theme->errors() );
        }
    }
    return;
}
 
Arguments
  1. "/home/farmaboo/domains/underbodyguards.com/public_html/wp-content/themes/wph/archive.php"
    
/home/farmaboo/domains/underbodyguards.com/public_html/wp-blog-header.php
<?php
/**
 * Loads the WordPress environment and template.
 *
 * @package WordPress
 */
 
if ( ! isset( $wp_did_header ) ) {
 
    $wp_did_header = true;
 
    // Load the WordPress library.
    require_once __DIR__ . '/wp-load.php';
 
    // Set up the WordPress query.
    wp();
 
    // Load the theme template.
    require_once ABSPATH . WPINC . '/template-loader.php';
 
}
 
Arguments
  1. "/home/farmaboo/domains/underbodyguards.com/public_html/wp-includes/template-loader.php"
    
/home/farmaboo/domains/underbodyguards.com/public_html/index.php
<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */
 
/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define( 'WP_USE_THEMES', true );
 
/** Loads the WordPress Environment and Template */
require __DIR__ . '/wp-blog-header.php';
 
Arguments
  1. "/home/farmaboo/domains/underbodyguards.com/public_html/wp-blog-header.php"
    

Environment & details:

empty
empty
empty
empty
empty
Key Value
SERVER_SOFTWARE
"Apache/2"
REQUEST_URI
"/post-category/%d0%b1%d0%b5%d0%b7-%d1%80%d1%83%d0%b1%d1%80%d0%b8%d0%ba%d0%b8/"
PATH
"/usr/local/bin:/usr/bin:/bin"
TEMP
"/tmp"
TMP
"/tmp"
TMPDIR
"/tmp"
PWD
"/"
HTTP_ACCEPT
"*/*"
HTTP_ACCEPT_ENCODING
"gzip, br, zstd, deflate"
HTTP_CONNECTION
"close"
CONTENT_LENGTH
"0"
HTTP_HOST
"underbodyguards.com"
HTTP_REFERER
"https://underbodyguards.com/post-category/%d0%b1%d0%b5%d0%b7-%d1%80%d1%83%d0%b1%d1%80%d0%b8%d0%ba%d0%b8"
HTTP_USER_AGENT
"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)"
HTTP_X_FORWARDED_FOR
"216.73.216.171"
HTTP_X_ACCEL_INTERNAL
"/nginx_static_files"
REDIRECT_UNIQUE_ID
"adQqwRCNHKXxdi8tOIpcMAAAABo"
REDIRECT_HTTP_AUTHORIZATION
""
REDIRECT_HTTPS
"on"
REDIRECT_STATUS
"200"
UNIQUE_ID
"adQqwRCNHKXxdi8tOIpcMAAAABo"
HTTP_AUTHORIZATION
""
HTTPS
"on"
SERVER_SIGNATURE
""
SERVER_NAME
"underbodyguards.com"
SERVER_ADDR
"95.168.171.175"
SERVER_PORT
"443"
REMOTE_ADDR
"216.73.216.171"
DOCUMENT_ROOT
"/home/farmaboo/domains/underbodyguards.com/private_html"
REQUEST_SCHEME
"https"
CONTEXT_PREFIX
""
CONTEXT_DOCUMENT_ROOT
"/home/farmaboo/domains/underbodyguards.com/private_html"
SERVER_ADMIN
"webmaster@underbodyguards.com"
SCRIPT_FILENAME
"/home/farmaboo/domains/underbodyguards.com/private_html/index.php"
REMOTE_PORT
"47920"
REDIRECT_URL
"/post-category/без-рубрики/"
SERVER_PROTOCOL
"HTTP/1.0"
REQUEST_METHOD
"GET"
QUERY_STRING
""
SCRIPT_NAME
"/index.php"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1775512257.5845
REQUEST_TIME
1775512257
empty
0. Whoops\Handler\PrettyPageHandler