$g['xchan_photo_s'], 'name' => '@' . $g['xchan_name'], 'id' => $g['abook_id'], 'link' => $g['xchan_url'], 'label' => '', 'nick' => '', ]; } } } if($do_tags) { $r = q("select distinct term, tid, url from term where ttype in ( %d, %d ) $tag_sql_extra group by term order by term asc", intval(TERM_HASHTAG), intval(TERM_COMMUNITYTAG) ); if($r) { foreach($r as $g) { $results[] = [ 'photo' => z_root() . '/images/hashtag.png', 'name' => '#' . $g['term'], 'id' => $g['tid'], 'link' => $g['url'], 'label' => '', 'nick' => '', ]; } } } header("content-type: application/json"); $o = array( 'start' => $start, 'count' => $count, 'items' => $results, ); echo json_encode($o); killme(); } }