4 function match_content(&$a) {
10 $o .= '<h2>' . t('Profile Match') . '</h2>';
12 $r = q("SELECT `pub_keywords`, `prv_keywords` FROM `profile` WHERE `is-default` = 1 AND `uid` = %d LIMIT 1",
17 if(! $r[0]['pub_keywords'] && (! $r[0]['prv_keywords'])) {
18 notice( t('No keywords to match. Please add keywords to your default profile.') . EOL);
24 $tags = trim($r[0]['pub_keywords'] . ' ' . $r[0]['prv_keywords']);
28 if($a->pager['page'] != 1)
29 $params['p'] = $a->pager['page'];
31 if(strlen(get_config('system','directory_submit_url')))
32 $x = post_url('http://dir.friendika.com/msearch', $params);
34 $x = post_url($a->get_baseurl() . '/msearch', $params);
39 $a->set_pager_total($j->total);
40 $a->set_pager_itemspage($j->items_page);
43 if(count($j->results)) {
45 $tpl = get_markup_template('match.tpl');
46 foreach($j->results as $jj) {
48 $o .= replace_macros($tpl,array(
51 '$photo' => $jj->photo,
57 info( t('No matches') . EOL);