PHP 8.2.31
Preview: bbpress.php Size: 1.97 KB
/home/nshryvcy/himaltourism.com/wp-content/plugins/jetpack/3rd-party/bbpress.php

<?php
/**
 * Compatibility functions for bbpress.
 *
 * @package automattic/jetpack
 */

add_action( 'init', 'jetpack_bbpress_compat', 11 ); // Priority 11 needed to ensure sharing_display is loaded.

/**
 * Adds Jetpack + bbPress Compatibility filters.
 *
 * @author Brandon Kraft
 * @since  3.7.1
 */
function jetpack_bbpress_compat() {
	if ( ! function_exists( 'bbpress' ) ) {
		return;
	}

	/**
	 * Add compatibility layer for REST API.
	 *
	 * @since 8.5.0 Moved from root-level file and check_rest_api_compat()
	 */
	require_once __DIR__ . '/class-jetpack-bbpress-rest-api.php';
	Jetpack_BbPress_REST_API::instance();

	// Adds sharing buttons to bbPress items.
	if ( function_exists( 'sharing_display' ) ) {
		add_filter( 'bbp_get_topic_content', 'sharing_display', 19 );
		add_action( 'bbp_template_after_single_forum', 'jetpack_sharing_bbpress' );
		add_action( 'bbp_template_after_single_topic', 'jetpack_sharing_bbpress' );
	}

	/**
	 * Enable Markdown support for bbpress post types.
	 *
	 * @author Brandon Kraft
	 * @since 6.0.0
	 */
	if ( function_exists( 'bbp_get_topic_post_type' ) ) {
		add_post_type_support( bbp_get_topic_post_type(), 'wpcom-markdown' );
		add_post_type_support( bbp_get_reply_post_type(), 'wpcom-markdown' );
		add_post_type_support( bbp_get_forum_post_type(), 'wpcom-markdown' );
	}

	/**
	 * Use Photon for all images in Topics and replies.
	 *
	 * @since 4.9.0
	 */
	if ( class_exists( 'Jetpack_Photon' ) && Jetpack::is_module_active( 'photon' ) ) {
		add_filter( 'bbp_get_topic_content', array( 'Jetpack_Photon', 'filter_the_content' ), 999999 );
		add_filter( 'bbp_get_reply_content', array( 'Jetpack_Photon', 'filter_the_content' ), 999999 );
	}
}

/**
 * Display Jetpack "Sharing" buttons on bbPress 2.x forums/ topics/ lead topics/ replies.
 *
 * Determination if the sharing buttons should display on the post type is handled within sharing_display().
 *
 * @author David Decker
 * @since  3.7.0
 */
function jetpack_sharing_bbpress() {
	sharing_display( null, true );
}

Directory Contents

Dirs: 1 × Files: 22

Name Size Perms Modified Actions
debug-bar DIR
- drwxr-xr-x 2023-04-04 05:35:20
Edit Download
2.17 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
1.97 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
452 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
941 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
503 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
4.12 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
4.39 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
2.33 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
3.63 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
4.39 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
16.83 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
3.04 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
815 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
733 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
2.57 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
2.55 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
638 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
2.04 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
974 B lrw-r--r-- 2023-04-04 05:35:20
Edit Download
3.48 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
3.57 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download
1.59 KB lrw-r--r-- 2023-04-04 05:35:20
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).