-
Notifications
You must be signed in to change notification settings - Fork 83
activitypub_post_location
github-actions[bot] edited this page Jan 22, 2026
·
2 revisions
Filter the location Place object for a post.
/**
* Filter the location Place object for a post.
*
* @param array $place
* @param WP_Post $post
* @param int $post_id
* @return array|null The filtered Place object or null to disable location.
*/
function my_activitypub_post_location_callback( array $place, WP_Post $post, int $post_id ) {
// Your code here.
return $place;
}
add_filter( 'activitypub_post_location', 'my_activitypub_post_location_callback', 10, 3 );-
array$placeThe Place object. -
WP_Post$postThe post object. -
int$post_idThe post ID.
array|null The filtered Place object or null to disable location.
\apply_filters( 'activitypub_post_location', $place, $this->item, $post_id )Follow @activitypub.blog@activitypub.blog for updates and news.