1
0
Fork 0
This commit is contained in:
Michael 2020-04-28 13:33:03 +00:00
commit 70e5639e29
17 changed files with 34 additions and 7 deletions

View file

@ -68,7 +68,7 @@ function msearch_post(App $a)
$perpage
);
while($search_result = DBA::fetch($search_stmt)) {
while ($search_result = DBA::fetch($search_stmt)) {
$results[] = [
'name' => $search_result['name'],
'url' => DI::baseUrl() . '/profile/' . $search_result['nickname'],
@ -77,6 +77,8 @@ function msearch_post(App $a)
];
}
DBA::close($search_stmt);
$output = ['total' => $total, 'items_page' => $perpage, 'page' => $page, 'results' => $results];
echo json_encode($output);