aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Suggest.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2021-03-12 10:07:15 +0000
committerMario <mario@mariovavti.com>2021-03-12 10:07:15 +0000
commit3f053611bdbbd4a26a5d9c76a294b7ada07f0726 (patch)
treeb8b16b780d0353ede8580b41ec9e16f622c94c87 /Zotlabs/Module/Suggest.php
parentc29261487cdecda4282df25769540bc4fa20631d (diff)
parent1582b8bc9620a661823c608c0c7023a70554214b (diff)
downloadvolse-hubzilla-3f053611bdbbd4a26a5d9c76a294b7ada07f0726.tar.gz
volse-hubzilla-3f053611bdbbd4a26a5d9c76a294b7ada07f0726.tar.bz2
volse-hubzilla-3f053611bdbbd4a26a5d9c76a294b7ada07f0726.zip
Merge branch 'dev' into air
Diffstat (limited to 'Zotlabs/Module/Suggest.php')
-rw-r--r--Zotlabs/Module/Suggest.php34
1 files changed, 17 insertions, 17 deletions
diff --git a/Zotlabs/Module/Suggest.php b/Zotlabs/Module/Suggest.php
index 18961214e..0ed6ea8d7 100644
--- a/Zotlabs/Module/Suggest.php
+++ b/Zotlabs/Module/Suggest.php
@@ -15,17 +15,17 @@ class Suggest extends \Zotlabs\Web\Controller {
if(! Apps::system_app_installed(local_channel(), 'Suggest Channels'))
return;
-
+
if(x($_GET,'ignore')) {
q("insert into xign ( uid, xchan ) values ( %d, '%s' ) ",
intval(local_channel()),
dbesc($_GET['ignore'])
);
}
-
+
}
-
-
+
+
function get() {
if(! local_channel()) {
@@ -45,22 +45,22 @@ class Suggest extends \Zotlabs\Web\Controller {
$o = '';
nav_set_selected('Suggest Channels');
-
+
$_SESSION['return_url'] = z_root() . '/' . \App::$cmd;
-
+
$r = suggestion_query(local_channel(),get_observer_hash());
-
+
if(! $r) {
info( t('No suggestions available. If this is a new site, please try again in 24 hours.'));
return;
}
-
+
$arr = array();
-
+
foreach($r as $rr) {
-
- $connlnk = z_root() . '/follow/?url=' . $rr['xchan_addr'];
-
+
+ $connlnk = z_root() . '/follow?f=&url=' . $rr['xchan_addr'];
+
$arr[] = array(
'url' => chanlink_url($rr['xchan_url']),
'common' => $rr['total'],
@@ -73,15 +73,15 @@ class Suggest extends \Zotlabs\Web\Controller {
'ignore' => t('Ignore/Hide')
);
}
-
-
+
+
$o = replace_macros(get_markup_template('suggest_page.tpl'),array(
'$title' => t('Channel Suggestions'),
'$entries' => $arr
));
-
+
return $o;
-
+
}
-
+
}