diff options
author | friendica <info@friendica.com> | 2013-12-08 20:08:50 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2013-12-08 20:08:50 -0800 |
commit | 082ac6777829c98ded48c271f4210ac5d6e1a68f (patch) | |
tree | 664a2ee7f0451640dac4d2672e40e3cfe044fcfb /include/contact_widgets.php | |
parent | 8959487f1c7e5b785df2f8e7658da8b2534b2ad9 (diff) | |
download | volse-hubzilla-082ac6777829c98ded48c271f4210ac5d6e1a68f.tar.gz volse-hubzilla-082ac6777829c98ded48c271f4210ac5d6e1a68f.tar.bz2 volse-hubzilla-082ac6777829c98ded48c271f4210ac5d6e1a68f.zip |
suggestion widget tweaked to make it comanche capable. Remove old versions of specs that are so obsolete it isn't funny. Zot protocol reference is in red's github wiki, and in the code. We should move the github copy to /doc once it is updated to match the code. There's no point in documenting dfrn in the red code base.
Diffstat (limited to 'include/contact_widgets.php')
-rw-r--r-- | include/contact_widgets.php | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/include/contact_widgets.php b/include/contact_widgets.php index 2fa5dee0b..ac5382862 100644 --- a/include/contact_widgets.php +++ b/include/contact_widgets.php @@ -153,55 +153,3 @@ function common_friends_visitor_widget($profile_uid) { }; -function suggest_widget() { - - require_once('include/socgraph.php'); - - $r = suggestion_query(local_user(),get_observer_hash(),0,20); - - if(! $r) { - return; - } - - $arr = array(); - - // Get two random entries from the top 20 returned. - // We'll grab the first one and the one immediately following. - // This will throw some entropy intot he situation so you won't - // be looking at the same two mug shots every time the widget runs - - - $index = ((count($r) > 2) ? mt_rand(0,count($r) - 2) : 0); - - - for($x = $index; $x <= ($index+1); $x ++) { - - $rr = $r[$x]; - if(! $rr['xchan_url']) - break; - - $connlnk = z_root() . '/follow/?url=' . $rr['xchan_addr']; - - $arr[] = array( - 'url' => chanlink_url($rr['xchan_url']), - 'profile' => $rr['xchan_url'], - 'name' => $rr['xchan_name'], - 'photo' => $rr['xchan_photo_m'], - 'ignlnk' => z_root() . '/suggest?ignore=' . $rr['xchan_hash'], - 'conntxt' => t('Connect'), - 'connlnk' => $connlnk, - 'ignore' => t('Ignore/Hide') - ); - } - - - $o = replace_macros(get_markup_template('suggest_widget.tpl'),array( - '$title' => t('Suggestions'), - '$more' => t('See more...'), - '$entries' => $arr - )); - - return $o; - -} - |