Skip to content

activitypub_before_get_content

github-actions[bot] edited this page Sep 12, 2025 · 11 revisions

Provides an action hook so plugins can add their own hooks/filters before AP content is generated.

Example: if a plugin adds a filter to the_content to add a button to the end of posts, it can also remove that filter here.

Auto-generated Example

/**
 * Provides an action hook so plugins can add their own hooks/filters before AP content is generated.
 * 
 * Example: if a plugin adds a filter to `the_content` to add a button to the end of posts, it can also remove that filter here.
 *
 * @param WP_Post $post 
 * @return WP_Post The filtered value.
 */
function my_activitypub_before_get_content_callback( WP_Post $post ) {
    // Your code here.
    return $post;
}
add_filter( 'activitypub_before_get_content', 'my_activitypub_before_get_content_callback' );

Parameters

  • WP_Post $post The post object.

Files

\do_action( 'activitypub_before_get_content', $post )

← All Hooks

Users

Developers

Clone this wiki locally