pings_open

The timeline below displays how wordpress function pings_open has changed across different WordPress versions. If a version is not listed, refer to the next available version below.

WordPress Version: 6.3

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post Optional. Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post = null)
{
    $_post = get_post($post);
    $post_id = $_post ? $_post->ID : 0;
    $pings_open = $_post && 'open' === $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $pings_open Whether the current post is open for pings.
     * @param int  $post_id    The post ID.
     */
    return apply_filters('pings_open', $pings_open, $post_id);
}

WordPress Version: 6.2

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post Optional. Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post = null)
{
    $_post = get_post($post);
    $post_id = $_post ? $_post->ID : 0;
    $open = $_post && 'open' === $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 6.1

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post = null)
{
    $_post = get_post($post);
    $post_id = $_post ? $_post->ID : 0;
    $open = $_post && 'open' === $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 5.9

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $post_id = $_post ? $_post->ID : 0;
    $open = $_post && 'open' === $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 5.5

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $post_id = $_post ? $_post->ID : 0;
    $open = 'open' === $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 5.1

/**
 * Determines whether the current post is open for pings.
 *
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $post_id = $_post ? $_post->ID : 0;
    $open = 'open' == $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 5.0

/**
 * Determines whether the current post is open for pings.
 * 
 * For more information on this and similar theme functions, check out
 * the {@link https://developer.wordpress.org/themes/basics/conditional-tags/ 
 * Conditional Tags} article in the Theme Developer Handbook.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $post_id = $_post ? $_post->ID : 0;
    $open = 'open' == $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 4.8

/**
 * Whether the current post is open for pings.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $post_id = $_post ? $_post->ID : 0;
    $open = 'open' == $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool $open    Whether the current post is open for pings.
     * @param int  $post_id The post ID.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 4.6

/**
 * Whether the current post is open for pings.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $open = 'open' == $_post->ping_status;
    /**
     * Filters whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool        $open    Whether the current post is open for pings.
     * @param int|WP_Post $post_id The post ID or WP_Post object.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 3.9

/**
 * Whether the current post is open for pings.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $open = 'open' == $_post->ping_status;
    /**
     * Filter whether the current post is open for pings.
     *
     * @since 2.5.0
     *
     * @param bool        $open    Whether the current post is open for pings.
     * @param int|WP_Post $post_id The post ID or WP_Post object.
     */
    return apply_filters('pings_open', $open, $post_id);
}

WordPress Version: 3.7

/**
 * Whether the current post is open for pings.
 *
 * @since 1.5.0
 *
 * @param int|WP_Post $post_id Optional. Post ID or WP_Post object. Default current post.
 * @return bool True if pings are accepted
 */
function pings_open($post_id = null)
{
    $_post = get_post($post_id);
    $open = 'open' == $_post->ping_status;
    return apply_filters('pings_open', $open, $post_id);
}