diff options
author | friendica <info@friendica.com> | 2012-05-01 21:22:27 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2012-05-01 21:22:27 -0700 |
commit | becdb1f5085f2561b8b0acebbdbf43e4a81d50da (patch) | |
tree | 9b9f482f611b6dd91866518387b79140c6567be7 /include/contact_widgets.php | |
parent | 1fab28c413d79a132b1592ff51db3729141d6998 (diff) | |
download | volse-hubzilla-becdb1f5085f2561b8b0acebbdbf43e4a81d50da.tar.gz volse-hubzilla-becdb1f5085f2561b8b0acebbdbf43e4a81d50da.tar.bz2 volse-hubzilla-becdb1f5085f2561b8b0acebbdbf43e4a81d50da.zip |
final touches - show friends in common with total strangers from different sites
Diffstat (limited to 'include/contact_widgets.php')
-rw-r--r-- | include/contact_widgets.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/include/contact_widgets.php b/include/contact_widgets.php index 3fd311e4a..cfe27c5c9 100644 --- a/include/contact_widgets.php +++ b/include/contact_widgets.php @@ -154,17 +154,22 @@ function common_friends_visitor_widget($profile_uid) { } } - if($zcid == 0) + if($cid == 0 && $zcid == 0) return; require_once('include/socgraph.php'); - - $t = count_common_friends_zcid($profile_uid,$zcid); + if($cid) + $t = count_common_friends($profile_uid,$cid); + else + $t = count_common_friends($profile_uid,$cid); if(! $t) return; - $r = common_friends_zcid($profile_uid,$zcid); + if($cid) + $r = common_friends($profile_uid,$cid,5); + else + $r = common_friends_zcid($profile_uid,$zcid); return replace_macros(get_markup_template('remote_friends_common.tpl'), array( '$desc' => sprintf( tt("%d friend in common", "%d friends in common", $t), $t), |