Whoops \ Exception \ ErrorException (E_NOTICE)
Trying to access array offset on value of type bool Whoops\Exception\ErrorException thrown with message "Trying to access array offset on value of type bool" Stacktrace: #30 Whoops\Exception\ErrorException in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/Models/Core/Attachments.php:116 #29 Whoops\Run:handleError in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/Models/Core/Attachments.php:116 #28 Syltaen\Attachments:populateThumbnailFormats in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/PostsModel.php:226 #27 Syltaen\PostsModel:populateResultData in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/Model.php:833 #26 Syltaen\Model:populateData in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/Model.php:605 #25 Syltaen\Model:get in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/hooks/filters/filters-forum.php:248 #24 Syltaen\Files:Syltaen\{closure} in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php:307 #23 WP_Hook:apply_filters in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php:331 #22 WP_Hook:do_action in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php:476 #21 do_action in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-single-reply.php:66 #20 require in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php:772 #19 load_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:103 #18 bbp_locate_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:41 #17 bbp_get_template_part in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-replies.php:35 #16 require in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php:772 #15 load_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:103 #14 bbp_locate_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:41 #13 bbp_get_template_part in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/content-single-topic.php:45 #12 require in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php:772 #11 load_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:103 #10 bbp_locate_template in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php:41 #9 bbp_get_template_part in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/common/shortcodes.php:342 #8 BBP_Shortcodes:display_topic in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/theme-compat.php:680 #7 bbp_template_include_theme_compat in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php:307 #6 WP_Hook:apply_filters in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php:191 #5 apply_filters in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/sub-actions.php:477 #4 bbp_template_include in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php:307 #3 WP_Hook:apply_filters in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php:191 #2 apply_filters in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template-loader.php:104 #1 require_once in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-blog-header.php:19 #0 require in /var/www/vhosts/bewapp.hungryminds.host/httpdocs/index.php:17
Stack frames (31)
30
Whoops\Exception\ErrorException
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/Models/Core/Attachments.php116
29
Whoops\Run handleError
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/Models/Core/Attachments.php116
28
Syltaen\Attachments populateThumbnailFormats
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/PostsModel.php226
27
Syltaen\PostsModel populateResultData
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/Model.php833
26
Syltaen\Model populateData
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/lib/Models/Model.php605
25
Syltaen\Model get
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/themes/syltaen/app/hooks/filters/filters-forum.php248
24
Syltaen\Files Syltaen\{closure}
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php307
23
WP_Hook apply_filters
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php331
22
WP_Hook do_action
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php476
21
do_action
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-single-reply.php66
20
require
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php772
19
load_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php103
18
bbp_locate_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php41
17
bbp_get_template_part
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-replies.php35
16
require
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php772
15
load_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php103
14
bbp_locate_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php41
13
bbp_get_template_part
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/content-single-topic.php45
12
require
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template.php772
11
load_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php103
10
bbp_locate_template
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/template-functions.php41
9
bbp_get_template_part
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/common/shortcodes.php342
8
BBP_Shortcodes display_topic
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/theme-compat.php680
7
bbp_template_include_theme_compat
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php307
6
WP_Hook apply_filters
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php191
5
apply_filters
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/includes/core/sub-actions.php477
4
bbp_template_include
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/class-wp-hook.php307
3
WP_Hook apply_filters
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/plugin.php191
2
apply_filters
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template-loader.php104
1
require_once
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/wp-blog-header.php19
0
require
/var/www/vhosts/bewapp.hungryminds.host/httpdocs/index.php17
    }
 
    /**
     * Add all thumbnail formats specified in the model to a post object
     *
     * @param WP_Post $post
     * @return void
     */
    protected function populateThumbnailFormats(&$attachment)
    {
        if (!static::HAS_THUMBNAIL) return false;
 
        $attachment->thumb = [
            "url" => [],
            "tag" => []
        ];
 
        if (!empty($this->thumbnailsFormats["url"])) {
            foreach ($this->thumbnailsFormats["url"] as $name=>$format) {
                $attachment->thumb["url"][$name] = wp_get_attachment_image_src($attachment->ID, $format)[0];
            }
        }
 
        if (!empty($this->thumbnailsFormats["tag"])) {
            foreach ($this->thumbnailsFormats["tag"] as $name=>$format) {
                $attachment->thumb["tag"][$name] = wp_get_attachment_image($attachment->ID, $format);
            }
        }
    }
}
Arguments
  1. "Trying to access array offset on value of type bool"
    
    }
 
    /**
     * Add all thumbnail formats specified in the model to a post object
     *
     * @param WP_Post $post
     * @return void
     */
    protected function populateThumbnailFormats(&$attachment)
    {
        if (!static::HAS_THUMBNAIL) return false;
 
        $attachment->thumb = [
            "url" => [],
            "tag" => []
        ];
 
        if (!empty($this->thumbnailsFormats["url"])) {
            foreach ($this->thumbnailsFormats["url"] as $name=>$format) {
                $attachment->thumb["url"][$name] = wp_get_attachment_image_src($attachment->ID, $format)[0];
            }
        }
 
        if (!empty($this->thumbnailsFormats["tag"])) {
            foreach ($this->thumbnailsFormats["tag"] as $name=>$format) {
                $attachment->thumb["tag"][$name] = wp_get_attachment_image($attachment->ID, $format);
            }
        }
    }
}
            $this->filters["post_type"] = [static::TYPE];
        }
        $this->filters["post_type"][] = $post_model::TYPE;
        $this->joinedModels[$post_model::TYPE] = $post_model;
        return $this;
    }
 
 
    // ==================================================
    // > DATA HANDLING FOR EACH POST
    // ==================================================
    /* Update parent method */
    public function populateResultData(&$post)
    {
        // if the post is not from this model, use the post's model
        if ($post->post_type !== static::TYPE) return $this->joinedModels[$post->post_type]->populateResultData($post);
 
        /* ADD THUMBNAIL FORMATS IF ANY */
        if ((!empty($this->thumbnailsFormats["url"]) || !empty($this->thumbnailsFormats["tag"])) && $this->hasAttr("thumb")) {
            $this->populateThumbnailFormats($post);
        }
 
        /* ADD TAXONOMIY TERMS IF ANY */
        if (!empty($this->termsFormats) && $this->hasAttr("terms")) {
            $this->populateTerms($post);
        }
 
        /* ADD POST URL IF PUBLIC */
        if ((static::HAS_PAGE) && $this->hasAttr("url")) {
            $this->populatePublicUrl($post);
        }
 
        /* COMMON */
        parent::populateResultData($post);
    }
 
    /**
     * Add all thumbnail formats specified in the model to a post object
     *
     * @param WP_Post $post
        if (in_array($module, $this->loadedModules)) return true;
 
        // Register the new load and say it wasn't loaded before
        $this->loadedModules[] = $module;
        return false;
    }
 
 
    /**
     * Add data to each result based on what the model supports
     *
     * @return self
     */
    public function populateData()
    {
        if (!isset($this->cachedQuery) || empty($this->cachedQuery)) die("The query need to be run before populating its results.");
 
        $results = static::getResultsFromQuery($this->cachedQuery);
        foreach ($results as $result) {
            $this->populateResultData($result);
        }
 
        return $this;
    }
 
    /**
     * Launch each populate method on a user
     *
     * @param object
     * @return void
     */
    public function populateResultData(&$result)
    {
        /* REMOVE ATTRIBUTES THAT SHOULD NOT BE RETRIEVED */
        if (!empty($this->attrs)) {
            $this->removeUnusedAttr($result);
        }
 
        /* ADD FIELDS IF ANY */
        if (!empty($this->fields)) {
    // ==================================================
    // > GETTERS
    // ==================================================
    /**
     * Execute the query and retrive all the found posts
     *
     * @param int $limit Number of posts to return
     * @param int $page Page offset to use
     * @return array of WP_Post
     */
    public function get($limit = false, $page = false)
    {
        $this->limit($limit)->page($page);
 
        // Only re-fetch posts if the query has been updated
        if ($this->filters !== $this->cachedFilters || !$this->cachedResults) {
            $this->cachedResults = static::getResultsFromQuery(
                $this
                    ->run()
                    ->populateData()
                    ->cachedQuery
            );
        }
 
        return $this->cachedResults;
    }
 
    /**
     * Only return the matching IDs without
     *
     * @return void
     */
    public function getIDs()
    {
        $this->filters["fields"] = "ids";
        $this->cachedResults = static::getResultsFromQuery(
            $this->run()->cachedQuery
        );
 
        return $this->cachedResults;
Hooks::add(["bbp_new_topic", "bbp_new_reply"], function ($post_id = 0, $parent_id = 0) {
    // Nothing to attach
    if (empty($_POST["attachments"])) return;
 
    $topic_id = bbp_is_topic($post_id) ? $post_id : $parent_id;
 
    // Move files to topic folder
    $files = array_filter(array_map(function ($file) use ($topic_id) {
        return Files::move($file, "forum/topic-" . $topic_id);
    }, json_decode(stripcslashes($_POST["attachments"]), true)));
 
    // Generate attachments & link to topic
    Files::generateAttachement($files, $post_id);
}, 10, 5);
 
 
Hooks::add("bbp_theme_after_reply_content", function () {
    global $post;
 
    $attachments = (new Attachments)->of($post->ID)->get();
    if (empty($attachments)) return;
 
    View::display("includes/archives/_archive-attachments", [
        "title" => sprintf(_n("Fichier joint :", "%s fichiers joints :", count($attachments), "syltaen"), count($attachments)),
        "attachments" => $attachments
    ]);
});
 
 
// ==================================================
// > FORCE TEXT PASTE
// ==================================================
add_filter("bbp_get_tiny_mce_plugins", function ($plugins = []) {
    $plugins[] = "paste";
    return $plugins;
});
 
        $nesting_level = $this->nesting_level++;
 
        $this->iterations[ $nesting_level ] = array_keys( $this->callbacks );
        $num_args                           = count( $args );
 
        do {
            $this->current_priority[ $nesting_level ] = current( $this->iterations[ $nesting_level ] );
            $priority                                 = $this->current_priority[ $nesting_level ];
 
            foreach ( $this->callbacks[ $priority ] as $the_ ) {
                if ( ! $this->doing_action ) {
                    $args[0] = $value;
                }
 
                // 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, (int) $the_['accepted_args'] ) );
                }
            }
        } while ( false !== next( $this->iterations[ $nesting_level ] ) );
 
        unset( $this->iterations[ $nesting_level ] );
        unset( $this->current_priority[ $nesting_level ] );
 
        $this->nesting_level--;
 
        return $value;
    }
 
    /**
     * Calls the callback functions that have been added to an action hook.
     *
     * @since 4.7.0
     *
     * @param array $args Parameters to pass to the callback functions.
        } while ( false !== next( $this->iterations[ $nesting_level ] ) );
 
        unset( $this->iterations[ $nesting_level ] );
        unset( $this->current_priority[ $nesting_level ] );
 
        $this->nesting_level--;
 
        return $value;
    }
 
    /**
     * Calls the callback functions that have been added to an action hook.
     *
     * @since 4.7.0
     *
     * @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;
        }
    }
 
    /**
     * Processes the functions hooked into the 'all' hook.
     *
     * @since 4.7.0
     *
     * @param array $args Arguments to pass to the hook callbacks. Passed by reference.
     */
    public function do_all_hook( &$args ) {
        $nesting_level                      = $this->nesting_level++;
        $this->iterations[ $nesting_level ] = array_keys( $this->callbacks );
 
        do {
            $priority = current( $this->iterations[ $nesting_level ] );
    if ( ! isset( $wp_filter[ $hook_name ] ) ) {
        if ( isset( $wp_filter['all'] ) ) {
            array_pop( $wp_current_filter );
        }
 
        return;
    }
 
    if ( ! isset( $wp_filter['all'] ) ) {
        $wp_current_filter[] = $hook_name;
    }
 
    if ( empty( $arg ) ) {
        $arg[] = '';
    } 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 );
}
 
/**
 * Calls the callback functions that have been added to an action hook, specifying arguments in an array.
 *
 * @since 2.1.0
 *
 * @see do_action() This function is identical, but the arguments passed to the
 *                  functions hooked to `$hook_name` are supplied using an array.
 *
 * @global WP_Hook[] $wp_filter         Stores all of the filters and actions.
 * @global int[]     $wp_actions        Stores the number of times each action was triggered.
 * @global string[]  $wp_current_filter Stores the list of current filters with the current one last.
 *
 * @param string $hook_name The name of the action to be executed.
 * @param array  $args      The arguments supplied to the functions hooked to `$hook_name`.
 */
function do_action_ref_array( $hook_name, $args ) {
 
            <?php do_action( 'bbp_theme_before_reply_author_admin_details' ); ?>
 
            <div class="bbp-reply-ip"><?php bbp_author_ip( bbp_get_reply_id() ); ?></div>
 
            <?php do_action( 'bbp_theme_after_reply_author_admin_details' ); ?>
 
        <?php endif; ?>
 
        <?php do_action( 'bbp_theme_after_reply_author_details' ); ?>
 
    </div><!-- .bbp-reply-author -->
 
    <div class="bbp-reply-content">
 
        <?php do_action( 'bbp_theme_before_reply_content' ); ?>
 
        <?php bbp_reply_content(); ?>
 
        <?php do_action( 'bbp_theme_after_reply_content' ); ?>
 
    </div><!-- .bbp-reply-content -->
</div><!-- .reply -->
 
        /*
         * 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/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-single-reply.php"
    
            // Check child theme first
            if ( file_exists( trailingslashit( $template_location ) . $template_name ) ) {
                $located = trailingslashit( $template_location ) . $template_name;
                break 2;
            }
        }
    }
 
    /**
     * This action exists only to follow the standard bbPress coding convention,
     * and should not be used to short-circuit any part of the template locator.
     *
     * If you want to override a specific template part, please either filter
     * 'bbp_get_template_part' or add a new location to the template stack.
     */
    do_action( 'bbp_locate_template', $located, $template_name, $template_names, $template_locations, $load, $require_once );
 
    // Maybe load the template if one was located
    if ( ( defined( 'WP_USE_THEMES' ) && WP_USE_THEMES ) && ( true === $load ) && ! empty( $located ) ) {
        load_template( $located, $require_once );
    }
 
    return $located;
}
 
/**
 * Locate an enqueueable file on the server. Used before being enqueued.
 *
 * If SCRIPT_DEBUG is set and the file includes a .min suffix, this function
 * will automatically attempt to locate a non-minified version of that file.
 *
 * If SCRIPT_DEBUG is not set and the file exclude a .min suffix, this function
 * will automatically attempt to locate a minified version of that file.
 *
 * See: https://bbpress.trac.wordpress.org/ticket/3218
 *
 * @since 2.6.0
 *
 * @param string $file
 *
 * @param string $slug
 * @param string $name Optional. Default null
 */
function bbp_get_template_part( $slug, $name = null ) {
 
    // Execute code for this part
    do_action( 'get_template_part_' . $slug, $slug, $name );
 
    // Setup possible parts
    $templates = array();
    if ( isset( $name ) ) {
        $templates[] = $slug . '-' . $name . '.php';
    }
    $templates[] = $slug . '.php';
 
    // Allow template parst to be filtered
    $templates = apply_filters( 'bbp_get_template_part', $templates, $slug, $name );
 
    // Return the part that is found
    return bbp_locate_template( $templates, true, false );
}
 
/**
 * Retrieve the name of the highest priority template file that exists.
 *
 * Searches in the child theme before parent theme so that themes which
 * inherit from a parent theme can just overload one file. If the template is
 * not found in either of those, it looks in the theme-compat folder last.
 *
 * @since 2.1.0 bbPress (r3618)
 *
 * @param string|array $template_names Template file(s) to search for, in order.
 * @param bool $load If true the template file will be loaded if it is found.
 * @param bool $require_once Whether to require_once or require. Default true.
 *                            Has no effect if $load is false.
 * @return string The template filename if one is located.
 */
function bbp_locate_template( $template_names, $load = false, $require_once = true ) {
 
    // No file found yet
 
    <li class="bbp-header">
        <div class="bbp-reply-author"><?php esc_html_e( 'Author',  'bbpress' ); ?></div><!-- .bbp-reply-author -->
        <div class="bbp-reply-content"><?php bbp_show_lead_topic()
            ? esc_html_e( 'Replies', 'bbpress' )
            : esc_html_e( 'Posts',   'bbpress' );
        ?></div><!-- .bbp-reply-content -->
    </li><!-- .bbp-header -->
 
    <li class="bbp-body">
 
        <?php if ( bbp_thread_replies() ) : ?>
 
            <?php bbp_list_replies(); ?>
 
        <?php else : ?>
 
            <?php while ( bbp_replies() ) : bbp_the_reply(); ?>
 
                <?php bbp_get_template_part( 'loop', 'single-reply' ); ?>
 
            <?php endwhile; ?>
 
        <?php endif; ?>
 
    </li><!-- .bbp-body -->
 
    <li class="bbp-footer">
        <div class="bbp-reply-author"><?php esc_html_e( 'Author',  'bbpress' ); ?></div>
        <div class="bbp-reply-content"><?php bbp_show_lead_topic()
            ? esc_html_e( 'Replies', 'bbpress' )
            : esc_html_e( 'Posts',   'bbpress' );
        ?></div><!-- .bbp-reply-content -->
    </li><!-- .bbp-footer -->
</ul><!-- #topic-<?php bbp_topic_id(); ?>-replies -->
 
<?php do_action( 'bbp_template_after_replies_loop' );
 
        /*
         * 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/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/loop-replies.php"
    
            // Check child theme first
            if ( file_exists( trailingslashit( $template_location ) . $template_name ) ) {
                $located = trailingslashit( $template_location ) . $template_name;
                break 2;
            }
        }
    }
 
    /**
     * This action exists only to follow the standard bbPress coding convention,
     * and should not be used to short-circuit any part of the template locator.
     *
     * If you want to override a specific template part, please either filter
     * 'bbp_get_template_part' or add a new location to the template stack.
     */
    do_action( 'bbp_locate_template', $located, $template_name, $template_names, $template_locations, $load, $require_once );
 
    // Maybe load the template if one was located
    if ( ( defined( 'WP_USE_THEMES' ) && WP_USE_THEMES ) && ( true === $load ) && ! empty( $located ) ) {
        load_template( $located, $require_once );
    }
 
    return $located;
}
 
/**
 * Locate an enqueueable file on the server. Used before being enqueued.
 *
 * If SCRIPT_DEBUG is set and the file includes a .min suffix, this function
 * will automatically attempt to locate a non-minified version of that file.
 *
 * If SCRIPT_DEBUG is not set and the file exclude a .min suffix, this function
 * will automatically attempt to locate a minified version of that file.
 *
 * See: https://bbpress.trac.wordpress.org/ticket/3218
 *
 * @since 2.6.0
 *
 * @param string $file
 *
 * @param string $slug
 * @param string $name Optional. Default null
 */
function bbp_get_template_part( $slug, $name = null ) {
 
    // Execute code for this part
    do_action( 'get_template_part_' . $slug, $slug, $name );
 
    // Setup possible parts
    $templates = array();
    if ( isset( $name ) ) {
        $templates[] = $slug . '-' . $name . '.php';
    }
    $templates[] = $slug . '.php';
 
    // Allow template parst to be filtered
    $templates = apply_filters( 'bbp_get_template_part', $templates, $slug, $name );
 
    // Return the part that is found
    return bbp_locate_template( $templates, true, false );
}
 
/**
 * Retrieve the name of the highest priority template file that exists.
 *
 * Searches in the child theme before parent theme so that themes which
 * inherit from a parent theme can just overload one file. If the template is
 * not found in either of those, it looks in the theme-compat folder last.
 *
 * @since 2.1.0 bbPress (r3618)
 *
 * @param string|array $template_names Template file(s) to search for, in order.
 * @param bool $load If true the template file will be loaded if it is found.
 * @param bool $require_once Whether to require_once or require. Default true.
 *                            Has no effect if $load is false.
 * @return string The template filename if one is located.
 */
function bbp_locate_template( $template_names, $load = false, $require_once = true ) {
 
    // No file found yet
 
        <?php bbp_get_template_part( 'form', 'protected' ); ?>
 
    <?php else : ?>
 
        <?php bbp_topic_tag_list(); ?>
 
        <?php bbp_single_topic_description(); ?>
 
        <?php if ( bbp_show_lead_topic() ) : ?>
 
            <?php bbp_get_template_part( 'content', 'single-topic-lead' ); ?>
 
        <?php endif; ?>
 
        <?php if ( bbp_has_replies() ) : ?>
 
            <?php bbp_get_template_part( 'pagination', 'replies' ); ?>
 
            <?php bbp_get_template_part( 'loop',       'replies' ); ?>
 
            <?php bbp_get_template_part( 'pagination', 'replies' ); ?>
 
        <?php endif; ?>
 
        <?php bbp_get_template_part( 'form', 'reply' ); ?>
 
    <?php endif; ?>
 
    <?php bbp_get_template_part( 'alert', 'topic-lock' ); ?>
 
    <?php do_action( 'bbp_template_after_single_topic' ); ?>
 
</div>
 
        /*
         * 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/vhosts/bewapp.hungryminds.host/httpdocs/wp-content/plugins/bbpress/templates/default/bbpress/content-single-topic.php"
    
            // Check child theme first
            if ( file_exists( trailingslashit( $template_location ) . $template_name ) ) {
                $located = trailingslashit( $template_location ) . $template_name;
                break 2;
            }
        }
    }
 
    /**
     * This action exists only to follow the standard bbPress coding convention,
     * and should not be used to short-circuit any part of the template locator.
     *
     * If you want to override a specific template part, please either filter
     * 'bbp_get_template_part' or add a new location to the template stack.
     */
    do_action( 'bbp_locate_template', $located, $template_name, $template_names, $template_locations, $load, $require_once );
 
    // Maybe load the template if one was located
    if ( ( defined( 'WP_USE_THEMES' ) && WP_USE_THEMES ) && ( true === $load ) && ! empty( $located ) ) {
        load_template( $located, $require_once );
    }
 
    return $located;
}
 
/**
 * Locate an enqueueable file on the server. Used before being enqueued.
 *
 * If SCRIPT_DEBUG is set and the file includes a .min suffix, this function
 * will automatically attempt to locate a non-minified version of that file.
 *
 * If SCRIPT_DEBUG is not set and the file exclude a .min suffix, this function
 * will automatically attempt to locate a minified version of that file.
 *
 * See: https://bbpress.trac.wordpress.org/ticket/3218
 *
 * @since 2.6.0
 *
 * @param string $file
 *
 * @param string $slug
 * @param string $name Optional. Default null
 */
function bbp_get_template_part( $slug, $name = null ) {
 
    // Execute code for this part
    do_action( 'get_template_part_' . $slug, $slug, $name );
 
    // Setup possible parts
    $templates = array();
    if ( isset( $name ) ) {
        $templates[] = $slug . '-' . $name . '.php';
    }
    $templates[] = $slug . '.php';
 
    // Allow template parst to be filtered
    $templates = apply_filters( 'bbp_get_template_part', $templates, $slug, $name );
 
    // Return the part that is found
    return bbp_locate_template( $templates, true, false );
}
 
/**
 * Retrieve the name of the highest priority template file that exists.
 *
 * Searches in the child theme before parent theme so that themes which
 * inherit from a parent theme can just overload one file. If the template is
 * not found in either of those, it looks in the theme-compat folder last.
 *
 * @since 2.1.0 bbPress (r3618)
 *
 * @param string|array $template_names Template file(s) to search for, in order.
 * @param bool $load If true the template file will be loaded if it is found.
 * @param bool $require_once Whether to require_once or require. Default true.
 *                            Has no effect if $load is false.
 * @return string The template filename if one is located.
 */
function bbp_locate_template( $template_names, $load = false, $require_once = true ) {
 
    // No file found yet
 
            $bbp = bbpress();
 
            // Reset necessary forum_query attributes for topics loop to function
            $bbp->forum_query->query_vars['post_type'] = bbp_get_forum_post_type();
            $bbp->forum_query->in_the_loop             = true;
            $bbp->forum_query->post                    = get_post( $forum_id );
 
            // Reset necessary topic_query attributes for topics loop to function
            $bbp->topic_query->query_vars['post_type'] = bbp_get_topic_post_type();
            $bbp->topic_query->in_the_loop             = true;
            $bbp->topic_query->post                    = get_post( $topic_id );
        }
 
        // Start output buffer
        $this->start( 'bbp_single_topic' );
 
        // Check forum caps
        if ( bbp_user_can_view_forum( array( 'forum_id' => $forum_id ) ) ) {
            bbp_get_template_part( 'content', 'single-topic' );
 
        // Forum is private and user does not have caps
        } elseif ( bbp_is_forum_private( $forum_id, false ) ) {
            bbp_get_template_part( 'feedback', 'no-access'    );
        }
 
        // Return contents of output buffer
        return $this->end();
    }
 
    /**
     * Display the topic form in an output buffer and return to ensure
     * post/page contents are displayed first.
     *
     * Supports 'forum_id' attribute to display the topic form for a particular
     * forum. This currently has styling issues from not being wrapped in
     * <div id="bbpress-forums" class="bbpress-wrapper"></div> which will need to be sorted out later.
     *
     * @since 2.0.0 bbPress (r3031)
     *
    } elseif ( bbp_is_topic_edit() || bbp_is_single_topic() ) {
 
        // Split
        if ( bbp_is_topic_split() ) {
            $new_content = bbp_buffer_template_part( 'form', 'topic-split', false );
 
        // Merge
        } elseif ( bbp_is_topic_merge() ) {
            $new_content = bbp_buffer_template_part( 'form', 'topic-merge', false );
 
        // Edit
        } elseif ( bbp_is_topic_edit() ) {
            $new_content = $bbp_shortcodes->display_topic_form();
 
            // Lock the topic from other edits
            bbp_set_post_lock( bbp_get_topic_id() );
 
        // Single
        } else {
            $new_content = $bbp_shortcodes->display_topic( array( 'id' => bbp_get_topic_id() ) );
        }
 
        // Reset post
        bbp_theme_compat_reset_post( array(
            'ID'             => bbp_get_topic_id(),
            'post_title'     => bbp_get_topic_title(),
            'post_author'    => bbp_get_topic_author_id(),
            'post_date'      => bbp_get_empty_datetime(),
            'post_content'   => $new_content,
            'post_type'      => bbp_get_topic_post_type(),
            'post_status'    => bbp_get_topic_status(),
            'is_single'      => true,
            'comment_status' => 'closed'
        ) );
 
    /** Replies ***********************************************************/
 
    // Reply archive
    } elseif ( is_post_type_archive( bbp_get_reply_post_type() ) ) {
 
 
        $nesting_level = $this->nesting_level++;
 
        $this->iterations[ $nesting_level ] = array_keys( $this->callbacks );
        $num_args                           = count( $args );
 
        do {
            $this->current_priority[ $nesting_level ] = current( $this->iterations[ $nesting_level ] );
            $priority                                 = $this->current_priority[ $nesting_level ];
 
            foreach ( $this->callbacks[ $priority ] as $the_ ) {
                if ( ! $this->doing_action ) {
                    $args[0] = $value;
                }
 
                // 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, (int) $the_['accepted_args'] ) );
                }
            }
        } while ( false !== next( $this->iterations[ $nesting_level ] ) );
 
        unset( $this->iterations[ $nesting_level ] );
        unset( $this->current_priority[ $nesting_level ] );
 
        $this->nesting_level--;
 
        return $value;
    }
 
    /**
     * Calls the callback functions that have been added to an action hook.
     *
     * @since 4.7.0
     *
     * @param array $args Parameters to pass to the callback functions.
        $all_args = func_get_args(); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue.NeedsInspection
        _wp_call_all_hook( $all_args );
    }
 
    if ( ! isset( $wp_filter[ $hook_name ] ) ) {
        if ( isset( $wp_filter['all'] ) ) {
            array_pop( $wp_current_filter );
        }
 
        return $value;
    }
 
    if ( ! isset( $wp_filter['all'] ) ) {
        $wp_current_filter[] = $hook_name;
    }
 
    // Pass the value to WP_Hook.
    array_unshift( $args, $value );
 
    $filtered = $wp_filter[ $hook_name ]->apply_filters( $value, $args );
 
    array_pop( $wp_current_filter );
 
    return $filtered;
}
 
/**
 * Calls the callback functions that have been added to a filter hook, specifying arguments in an array.
 *
 * @since 3.0.0
 *
 * @see apply_filters() This function is identical, but the arguments passed to the
 *                      functions hooked to `$hook_name` are supplied using an array.
 *
 * @global WP_Hook[] $wp_filter         Stores all of the filters and actions.
 * @global string[]  $wp_current_filter Stores the list of current filters with the current one last.
 *
 * @param string $hook_name The name of the filter hook.
 * @param array  $args      The arguments supplied to the functions hooked to `$hook_name`.
 * @return mixed The filtered value after all hooked functions are applied to it.
 */
function bbp_request( $query_vars = array() ) {
 
    // Filter & return
    return apply_filters( 'bbp_request', $query_vars );
}
 
/**
 * The main filter used for theme compatibility and displaying custom bbPress
 * theme files.
 *
 * @since 2.0.0 bbPress (r3311)
 *
 * @param string $template
 * @return string Template file to use
 */
function bbp_template_include( $template = '' ) {
 
    // Filter & return
    return apply_filters( 'bbp_template_include', $template );
}
 
/**
 * Generate bbPress-specific rewrite rules
 *
 * @since 2.0.0 bbPress (r2688)
 *
 * @deprecated 2.4.0 bbPress (r4918)
 *
 * @param WP_Rewrite $wp_rewrite
 */
function bbp_generate_rewrite_rules( $wp_rewrite ) {
    do_action_ref_array( 'bbp_generate_rewrite_rules', array( &$wp_rewrite ) );
}
 
/**
 * Filter the allowed themes list for bbPress specific themes
 *
 * @since 2.0.0 bbPress (r2944)
 *
 
        $nesting_level = $this->nesting_level++;
 
        $this->iterations[ $nesting_level ] = array_keys( $this->callbacks );
        $num_args                           = count( $args );
 
        do {
            $this->current_priority[ $nesting_level ] = current( $this->iterations[ $nesting_level ] );
            $priority                                 = $this->current_priority[ $nesting_level ];
 
            foreach ( $this->callbacks[ $priority ] as $the_ ) {
                if ( ! $this->doing_action ) {
                    $args[0] = $value;
                }
 
                // 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, (int) $the_['accepted_args'] ) );
                }
            }
        } while ( false !== next( $this->iterations[ $nesting_level ] ) );
 
        unset( $this->iterations[ $nesting_level ] );
        unset( $this->current_priority[ $nesting_level ] );
 
        $this->nesting_level--;
 
        return $value;
    }
 
    /**
     * Calls the callback functions that have been added to an action hook.
     *
     * @since 4.7.0
     *
     * @param array $args Parameters to pass to the callback functions.
        $all_args = func_get_args(); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue.NeedsInspection
        _wp_call_all_hook( $all_args );
    }
 
    if ( ! isset( $wp_filter[ $hook_name ] ) ) {
        if ( isset( $wp_filter['all'] ) ) {
            array_pop( $wp_current_filter );
        }
 
        return $value;
    }
 
    if ( ! isset( $wp_filter['all'] ) ) {
        $wp_current_filter[] = $hook_name;
    }
 
    // Pass the value to WP_Hook.
    array_unshift( $args, $value );
 
    $filtered = $wp_filter[ $hook_name ]->apply_filters( $value, $args );
 
    array_pop( $wp_current_filter );
 
    return $filtered;
}
 
/**
 * Calls the callback functions that have been added to a filter hook, specifying arguments in an array.
 *
 * @since 3.0.0
 *
 * @see apply_filters() This function is identical, but the arguments passed to the
 *                      functions hooked to `$hook_name` are supplied using an array.
 *
 * @global WP_Hook[] $wp_filter         Stores all of the filters and actions.
 * @global string[]  $wp_current_filter Stores the list of current filters with the current one last.
 *
 * @param string $hook_name The name of the filter hook.
 * @param array  $args      The arguments supplied to the functions hooked to `$hook_name`.
 * @return mixed The filtered value after all hooked functions are applied to it.
            if ( 'is_attachment' === $tag ) {
                remove_filter( 'the_content', 'prepend_attachment' );
            }
 
            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;
}
 
<?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/vhosts/bewapp.hungryminds.host/httpdocs/wp-includes/template-loader.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/vhosts/bewapp.hungryminds.host/httpdocs/wp-blog-header.php"
    

Environment & details:

empty
empty
empty
empty
empty
Key Value
SERVER_SOFTWARE
"Apache"
REQUEST_URI
"/forum/sujet/comment-etre-plus-efficace-en-matiere-de-repression/"
USER
"bewapp"
HOME
"/var/www/vhosts/bewapp.hungryminds.host"
SCRIPT_NAME
"/index.php"
QUERY_STRING
""
REQUEST_METHOD
"GET"
SERVER_PROTOCOL
"HTTP/1.0"
GATEWAY_INTERFACE
"CGI/1.1"
REDIRECT_URL
"/forum/sujet/comment-etre-plus-efficace-en-matiere-de-repression/"
REMOTE_PORT
"57552"
SCRIPT_FILENAME
"/var/www/vhosts/bewapp.hungryminds.host/httpdocs/index.php"
SERVER_ADMIN
"[no address given]"
CONTEXT_DOCUMENT_ROOT
"/var/www/vhosts/bewapp.hungryminds.host/httpdocs"
CONTEXT_PREFIX
""
REQUEST_SCHEME
"https"
DOCUMENT_ROOT
"/var/www/vhosts/bewapp.hungryminds.host/httpdocs"
REMOTE_ADDR
"18.232.31.206"
SERVER_PORT
"443"
SERVER_ADDR
"172.31.40.112"
SERVER_NAME
"bewapp.hungryminds.host"
SERVER_SIGNATURE
"<address>Apache Server at bewapp.hungryminds.host Port 443</address>\n"
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
HTTP_ACCEPT_ENCODING
"br,gzip"
HTTP_ACCEPT_LANGUAGE
"en-US,en;q=0.5"
HTTP_ACCEPT
"text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"
HTTP_USER_AGENT
"CCBot/2.0 (https://commoncrawl.org/faq/)"
HTTP_CONNECTION
"close"
HTTP_X_REAL_IP
"18.232.31.206"
HTTP_HOST
"bewapp.hungryminds.host"
proxy-nokeepalive
"1"
HTTPS
"on"
HTTP_AUTHORIZATION
""
UNIQUE_ID
"Y9YJfawfKHAAADruhXsAAAAI"
REDIRECT_STATUS
"200"
REDIRECT_HTTPS
"on"
REDIRECT_HTTP_AUTHORIZATION
""
REDIRECT_UNIQUE_ID
"Y9YJfawfKHAAADruhXsAAAAI"
FCGI_ROLE
"RESPONDER"
PHP_SELF
"/index.php"
REQUEST_TIME_FLOAT
1674971517.5617
REQUEST_TIME
1674971517
empty
0. Whoops\Handler\PrettyPageHandler