4 use Friendica\Database\DBM;
6 function viewsrc_content(App $a) {
9 notice( t('Access denied.') . EOL);
13 $item_id = (($a->argc > 1) ? intval($a->argv[1]) : 0);
17 notice( t('Item not found.') . EOL);
21 $r = q("SELECT `item`.`body` FROM `item`
22 WHERE `item`.`uid` = %d AND `item`.`visible` = 1 AND `item`.`deleted` = 0
23 and `item`.`moderated` = 0
24 AND `item`.`id` = '%s' LIMIT 1",
29 if (DBM::is_result($r))
31 echo str_replace("\n",'<br />',$r[0]['body']);
34 $o .= str_replace("\n",'<br />',$r[0]['body']);