laipower/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-json.php

20 lines
579 B
PHP
Raw Normal View History

2024-02-08 12:31:51 +00:00
<?php
$user = new \Activitypub\Model\Blog_User();
$user->set_context(
\Activitypub\Activity\Activity::CONTEXT
);
/*
* Action triggerd prior to the ActivityPub profile being created and sent to the client
*/
\do_action( 'activitypub_json_author_pre', $user->get__id() );
\header( 'Content-Type: application/activity+json' );
2024-03-28 09:40:10 +00:00
echo $user->to_json(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
2024-02-08 12:31:51 +00:00
/*
* Action triggerd after the ActivityPub profile has been created and sent to the client
*/
\do_action( 'activitypub_json_author_post', $user->get__id() );