3 namespace Friendica\Module;
5 use Friendica\Content\Text\HTML;
6 use Friendica\Core\L10n;
7 use Friendica\Core\Renderer;
9 use Friendica\Protocol\ActivityPub\Processor;
10 use Friendica\Protocol\Diaspora;
13 * @author Hypolite Petovan <mrpetovan@gmail.com>
15 class Itemsource extends \Friendica\BaseModule
17 public static function content()
19 if (!is_site_admin()) {
25 if (!empty($a->argv[1])) {
29 $guid = defaults($_REQUEST['guid'], $guid);
36 $item = Model\Item::selectFirst(['id', 'guid', 'uri'], ['guid' => $guid]);
38 $conversation = Model\Conversation::getByItemUri($item['uri']);
40 $item_id = $item['id'];
41 $item_uri = $item['uri'];
42 $source = $conversation['source'];
43 $terms = Model\Term::tagArrayFromItemId($item['id'], [Model\Term::HASHTAG, Model\Term::MENTION, Model\Term::IMPLICIT_MENTION]);
46 $tpl = Renderer::getMarkupTemplate('debug/itemsource.tpl');
47 $o = Renderer::replaceMacros($tpl, [
48 '$guid' => ['guid', L10n::t('Item Guid'), $guid, ''],
50 '$item_uri' => $item_uri,
51 '$item_id' => $item_id,