Back Back

X-periment 1 Asteroid

Explore our posts

Freever: a new way to keep your conversations private.
Whoops! There was an error.
Whoops \ Exception \ ErrorException (E_NOTICE)
Undefined offset: 0 Whoops\Exception\ErrorException thrown with message "Undefined offset: 0" Stacktrace: #8 Whoops\Exception\ErrorException in /var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php:47 #7 Whoops\Run:handleError in /var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php:47 #6 require in /var/www/html/wp-includes/template.php:772 #5 load_template in /var/www/html/wp-includes/template.php:716 #4 locate_template in /var/www/html/wp-includes/general-template.php:204 #3 get_template_part in /var/www/html/wp-content/themes/bksite-theme/index.php:160 #2 include in /var/www/html/wp-includes/template-loader.php:106 #1 require_once in /var/www/html/wp-blog-header.php:19 #0 require in /var/www/html/index.php:17
Stack frames (9)
8
Whoops\Exception\ErrorException
/loop-templates/content-card-small.php47
7
Whoops\Run handleError
/loop-templates/content-card-small.php47
6
require
/var/www/html/wp-includes/template.php772
5
load_template
/var/www/html/wp-includes/template.php716
4
locate_template
/var/www/html/wp-includes/general-template.php204
3
get_template_part
/index.php160
2
include
/var/www/html/wp-includes/template-loader.php106
1
require_once
/var/www/html/wp-blog-header.php19
0
require
/var/www/html/index.php17
/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php
                         class="card-img-top"
                         alt="<?php the_title(); ?>"
                    />
                <?php else: ?>
                    <img src="<?= get_stylesheet_directory_uri() ?>/static/images/xperiment/big-card.png"
                         class="card-img-top"
                         alt="<?php the_title(); ?>"
                    />
                <?php endif; ?>
            <?php endif; ?>
        </figure>
        <div class="imgOverlay">
            <?php
            $categories = get_the_category();
            $categories = array_filter($categories, function ($category) {
                return $category->slug !== 'featured' && $category->slug !== 'uncategorized';
            });
            ?>
            <?php if ($categories) : ?>
                <a href="<?= get_term_link($categories[0]->term_id) ?>"
                   class="categories"
                >
                    <?= $categories[0]->name ?>
                </a>
            <?php endif; ?>
        </div>
        <div class="card-body">
            <h5 class="card-title">
                <b>
                    <?php
                    if ( get_post_type() === 'news-rss' && $rss_link ) {
                        $post_link = $rss_link;
                    } else {
                        $post_link = get_the_permalink();
                    }
                    ?>
                    <a href="<?= $post_link ?>" target="<?= ($rss_link ? '_blank' : '_self')?>">
                        <?php the_title(); ?>
                    </a>
                </b>
Arguments
  1. "Undefined offset: 0"
    
/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php
                         class="card-img-top"
                         alt="<?php the_title(); ?>"
                    />
                <?php else: ?>
                    <img src="<?= get_stylesheet_directory_uri() ?>/static/images/xperiment/big-card.png"
                         class="card-img-top"
                         alt="<?php the_title(); ?>"
                    />
                <?php endif; ?>
            <?php endif; ?>
        </figure>
        <div class="imgOverlay">
            <?php
            $categories = get_the_category();
            $categories = array_filter($categories, function ($category) {
                return $category->slug !== 'featured' && $category->slug !== 'uncategorized';
            });
            ?>
            <?php if ($categories) : ?>
                <a href="<?= get_term_link($categories[0]->term_id) ?>"
                   class="categories"
                >
                    <?= $categories[0]->name ?>
                </a>
            <?php endif; ?>
        </div>
        <div class="card-body">
            <h5 class="card-title">
                <b>
                    <?php
                    if ( get_post_type() === 'news-rss' && $rss_link ) {
                        $post_link = $rss_link;
                    } else {
                        $post_link = get_the_permalink();
                    }
                    ?>
                    <a href="<?= $post_link ?>" target="<?= ($rss_link ? '_blank' : '_self')?>">
                        <?php the_title(); ?>
                    </a>
                </b>
Arguments
  1. 8
    
  2. "Undefined offset: 0"
    
  3. "/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php"
    
  4. 47
    
  5. array:80 [
      "_template_file" => "/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php"
      "require_once" => false
      "args" => []
      "posts" => & array:8 [
        0 => WP_Post {#6912}
        1 => WP_Post {#6913}
        2 => WP_Post {#6914}
        3 => WP_Post {#6915}
        4 => WP_Post {#6916}
        5 => WP_Post {#6917}
        6 => WP_Post {#6918}
        7 => WP_Post {#7245}
      ]
      "post" => & WP_Post {#7231}
      "wp_did_header" => & true
      "wp_query" => & WP_Query {#6079}
      "wp_rewrite" => & WP_Rewrite {#6080}
      "wpdb" => & wpdb {#5132}
      "wp_version" => & "5.8"
      "wp" => & WP {#6081}
      "id" => & 1080
      "comment" => & null
      "user_ID" => & 0
      "s" => ""
      "paged" => 2
      "pagename" => "x-periment-1-asteroid"
      "error" => ""
      "m" => ""
      "p" => 0
      "post_parent" => ""
      "subpost" => ""
      "subpost_id" => ""
      "attachment" => ""
      "attachment_id" => 0
      "name" => ""
      "page_id" => 0
      "second" => ""
      "minute" => ""
      "hour" => ""
      "day" => 0
      "monthnum" => 0
      "year" => 0
      "w" => 0
      "category_name" => ""
      "tag" => ""
      "cat" => ""
      "tag_id" => ""
      "author" => ""
      "author_name" => ""
      "feed" => ""
      "tb" => ""
      "meta_key" => ""
      "meta_value" => ""
      "preview" => ""
      "sentence" => ""
      "title" => ""
      "fields" => ""
      "menu_order" => ""
      "embed" => ""
      "category__in" => []
      "category__not_in" => []
      "category__and" => []
      "post__in" => []
      "post__not_in" => []
      "post_name__in" => []
      "tag__in" => []
      "tag__not_in" => []
      "tag__and" => []
      "tag_slug__in" => []
      "tag_slug__and" => []
      "post_parent__in" => []
      "post_parent__not_in" => []
      "author__in" => []
      "author__not_in" => []
      "ignore_sticky_posts" => false
      "suppress_filters" => false
      "cache_results" => true
      "update_post_term_cache" => true
      "lazy_load_term_meta" => true
      "update_post_meta_cache" => true
      "post_type" => ""
      "posts_per_page" => 10
      "nopaging" => false
      "comments_per_page" => "50"
      "no_found_rows" => false
      "order" => "DESC"
      "rss_link" => ""
      "thumbnail_url" => "https://bitskingdom.com/wp-content/uploads/2018/02/freever.jpg"
      "categories" => array:1 [
        1 => WP_Term {#7403}
      ]
    ]
    
/var/www/html/wp-includes/template.php
        /*
         * This use of extract() cannot be removed. There are many possible ways that
         * templates could depend on variables that it creates existing, and no way to
         * detect and deprecate it.
         *
         * Passing the EXTR_SKIP flag is the safest option, ensuring globals and
         * function variables cannot be overwritten.
         */
        // phpcs:ignore WordPress.PHP.DontExtract.extract_extract
        extract( $wp_query->query_vars, EXTR_SKIP );
    }
 
    if ( isset( $s ) ) {
        $s = esc_attr( $s );
    }
 
    if ( $require_once ) {
        require_once $_template_file;
    } else {
        require $_template_file;
    }
}
 
Arguments
  1. "/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php"
    
/var/www/html/wp-includes/template.php
function locate_template( $template_names, $load = false, $require_once = true, $args = array() ) {
    $located = '';
    foreach ( (array) $template_names as $template_name ) {
        if ( ! $template_name ) {
            continue;
        }
        if ( file_exists( STYLESHEETPATH . '/' . $template_name ) ) {
            $located = STYLESHEETPATH . '/' . $template_name;
            break;
        } elseif ( file_exists( TEMPLATEPATH . '/' . $template_name ) ) {
            $located = TEMPLATEPATH . '/' . $template_name;
            break;
        } elseif ( file_exists( ABSPATH . WPINC . '/theme-compat/' . $template_name ) ) {
            $located = ABSPATH . WPINC . '/theme-compat/' . $template_name;
            break;
        }
    }
 
    if ( $load && '' !== $located ) {
        load_template( $located, $require_once, $args );
    }
 
    return $located;
}
 
/**
 * Require the template file with WordPress environment.
 *
 * The globals are set up for the template file to ensure that the WordPress
 * environment is available from within the function. The query variables are
 * also available.
 *
 * @since 1.5.0
 * @since 5.5.0 The `$args` parameter was added.
 *
 * @global array      $posts
 * @global WP_Post    $post          Global post object.
 * @global bool       $wp_did_header
 * @global WP_Query   $wp_query      WordPress Query object.
 * @global WP_Rewrite $wp_rewrite    WordPress rewrite component.
Arguments
  1. "/var/www/html/wp-content/themes/bksite-theme/loop-templates/content-card-small.php"
    
  2. false
    
  3. []
    
/var/www/html/wp-includes/general-template.php
    if ( '' !== $name ) {
        $templates[] = "{$slug}-{$name}.php";
    }
 
    $templates[] = "{$slug}.php";
 
    /**
     * Fires before a template part is loaded.
     *
     * @since 5.2.0
     * @since 5.5.0 The `$args` parameter was added.
     *
     * @param string   $slug      The slug name for the generic template.
     * @param string   $name      The name of the specialized template.
     * @param string[] $templates Array of template files to search for, in order.
     * @param array    $args      Additional arguments passed to the template.
     */
    do_action( 'get_template_part', $slug, $name, $templates, $args );
 
    if ( ! locate_template( $templates, true, false, $args ) ) {
        return false;
    }
}
 
/**
 * Display search form.
 *
 * Will first attempt to locate the searchform.php file in either the child or
 * the parent, then load it. If it doesn't exist, then the default search form
 * will be displayed. The default search form is HTML, which will be displayed.
 * There is a filter applied to the search form HTML in order to edit or replace
 * it. The filter is {@see 'get_search_form'}.
 *
 * This function is primarily used by themes which want to hardcode the search
 * form into the sidebar and also by the search widget in WordPress.
 *
 * There is also an action that is called whenever the function is run called,
 * {@see 'pre_get_search_form'}. This can be useful for outputting JavaScript that the
 * search relies on or various formatting that applies to the beginning of the
 * search. To give a few examples of what it can be used for.
Arguments
  1. array:2 [
      0 => "loop-templates/content-card-small.php"
      1 => "loop-templates/content-card.php"
    ]
    
  2. true
    
  3. false
    
  4. []
    
/var/www/html/wp-content/themes/bksite-theme/index.php
        <div class="container">
            <div class="row">
                <?php
                wp_reset_postdata();
 
                $paged = ( get_query_var( 'paged' ) ) ? get_query_var( 'paged' ) : 1;
                $query = new WP_Query( [
                    'post_type'      => [ 'post', 'news-rss' ],
                    'posts_per_page' => 10,
                    'paged' => $paged
                ] );
                $i = 1;
 
                if ( $query->have_posts() ) {
                    while ( $query->have_posts() ) {
                        $query->the_post();
                        if ( $i === 1 || $i === 5 ) {
                            get_template_part( 'loop-templates/content-card', 'big' );
                        } else {
                            get_template_part( 'loop-templates/content-card', 'small' );
                        }
                        $i ++;
                    }
                } else {
                    get_template_part( 'loop-templates/content', 'none' );
                }
 
                wp_reset_postdata();
                ?>
            </div>
        </div>
    </section>
 
    <div class="col-12 mt-5 mb-5">
        <?php understrap_pagination(); ?>
    </div>
 
<?php get_footer( 'pages' ); ?>
Arguments
  1. "loop-templates/content-card"
    
  2. "small"
    
/var/www/html/wp-includes/template-loader.php
            }
 
            break;
        }
    }
 
    if ( ! $template ) {
        $template = get_index_template();
    }
 
    /**
     * Filters the path of the current template before including it.
     *
     * @since 3.0.0
     *
     * @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() );
        }
    }
    return;
}
 
Arguments
  1. "/var/www/html/wp-content/themes/bksite-theme/index.php"
    
/var/www/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. "/var/www/html/wp-includes/template-loader.php"
    
/var/www/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. "/var/www/html/wp-blog-header.php"
    

Environment & details:

empty
empty
empty
empty
empty
Key Value
SERVER_SOFTWARE
"Apache/2.4.38 (Debian)"
REQUEST_URI
"/x-periment-1-asteroid/page/2/"
REDIRECT_HTTP_AUTHORIZATION
""
REDIRECT_STATUS
"200"
HTTP_AUTHORIZATION
""
HTTP_HOST
"bitskingdom.com"
HTTP_X_REAL_IP
"44.192.22.242"
HTTP_X_FORWARDED_PROTO
"https"
HTTP_CONNECTION
"close"
HTTP_USER_AGENT
"CCBot/2.0 (https://commoncrawl.org/faq/)"
HTTP_ACCEPT
"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"
HTTP_ACCEPT_LANGUAGE
"en-US,en;q=0.5"
HTTP_ACCEPT_ENCODING
"br,gzip"
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
SERVER_SIGNATURE
"<address>Apache/2.4.38 (Debian) Server at bitskingdom.com Port 80</address>\n"
SERVER_NAME
"bitskingdom.com"
SERVER_ADDR
"172.26.0.3"
SERVER_PORT
"80"
REMOTE_ADDR
"44.192.22.242"
DOCUMENT_ROOT
"/var/www/html"
REQUEST_SCHEME
"http"
CONTEXT_PREFIX
""
CONTEXT_DOCUMENT_ROOT
"/var/www/html"
SERVER_ADMIN
"webmaster@localhost"
SCRIPT_FILENAME
"/var/www/html/index.php"
REMOTE_PORT
"42902"
REDIRECT_URL
"/x-periment-1-asteroid/page/2/"
GATEWAY_INTERFACE
"CGI/1.1"
SERVER_PROTOCOL
"HTTP/1.0"
REQUEST_METHOD
"GET"
QUERY_STRING
""
SCRIPT_NAME
"/index.php"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1628208858.5731
REQUEST_TIME
1628208858
argv
[]
argc
0
HTTPS
"on"
Key Value
HOSTNAME
"67c61c9f57c6"
PHP_VERSION
"7.4.20"
APACHE_CONFDIR
"/etc/apache2"
PHP_INI_DIR
"/usr/local/etc/php"
GPG_KEYS
"42670A7FE4D0441C8E4632349E4FDC074A4EF02D 5A52880781F755608BF815FC910DEB46F53EA312"
WORDPRESS_DEBUG
"1"
PHP_LDFLAGS
"-Wl,-O1 -pie"
PWD
"/var/www/html"
APACHE_LOG_DIR
"/var/log/apache2"
LANG
"C"
PHP_SHA256
"1fa46ca6790d780bf2cb48961df65f0ca3640c4533f0bca743cd61b71cb66335"
APACHE_PID_FILE
"/var/run/apache2/apache2.pid"
WORDPRESS_DB_HOST
"db:3306"
PHPIZE_DEPS
"autoconf \t\tdpkg-dev \t\tfile \t\tg++ \t\tgcc \t\tlibc-dev \t\tmake \t\tpkg-config \t\tre2c"
WORDPRESS_CONFIG_EXTRA
"""
/* wpconfig */\n
define( 'FS_METHOD', 'direct' );\n
define( 'WP_DEBUG_LOG', true );\n
define( 'WP_DEBUG_DISPLAY', false );\n
"""
PHP_URL
"https://www.php.net/distributions/php-7.4.20.tar.xz"
APACHE_RUN_GROUP
"www-data"
APACHE_LOCK_DIR
"/var/lock/apache2"
PHP_EXTRA_CONFIGURE_ARGS
"--with-apxs2 --disable-cgi"
SHLVL
"0"
PHP_CFLAGS
"-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
WORDPRESS_DB_PASSWORD
"wp_db_pass"
APACHE_RUN_DIR
"/var/run/apache2"
APACHE_ENVVARS
"/etc/apache2/envvars"
APACHE_RUN_USER
"www-data"
WORDPRESS_DB_USER
"wp_db_user"
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
WORDPRESS_DB_NAME
"wp_bk"
PHP_EXTRA_BUILD_DEPS
"apache2-dev"
PHP_ASC_URL
"https://www.php.net/distributions/php-7.4.20.tar.xz.asc"
PHP_CPPFLAGS
"-fstack-protector-strong -fpic -fpie -O2 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
0. Whoops\Handler\PrettyPageHandler