diff options
author | Mario <mario@mariovavti.com> | 2018-06-17 16:58:12 +0200 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2018-06-17 16:58:12 +0200 |
commit | 9c5df51141d68e50d3c1f5d3097160408debce48 (patch) | |
tree | d529d05124c26931a9b2c5ea097a6a4b03dd483a /include/text.php | |
parent | 9e29c136788fc14b9264843e11541bb6a2176e19 (diff) | |
download | volse-hubzilla-9c5df51141d68e50d3c1f5d3097160408debce48.tar.gz volse-hubzilla-9c5df51141d68e50d3c1f5d3097160408debce48.tar.bz2 volse-hubzilla-9c5df51141d68e50d3c1f5d3097160408debce48.zip |
some work on mod group
Diffstat (limited to 'include/text.php')
-rw-r--r-- | include/text.php | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/include/text.php b/include/text.php index a8c28d7bd..8bade6e90 100644 --- a/include/text.php +++ b/include/text.php @@ -1018,21 +1018,30 @@ function magiclink_url($observer,$myaddr,$url) { -function micropro($contact, $redirect = false, $class = '', $textmode = false) { +function micropro($contact, $redirect = false, $class = '', $mode = false) { if($contact['click']) $url = '#'; else $url = chanlink_hash($contact['xchan_hash']); - return replace_macros(get_markup_template(($textmode)?'micropro_txt.tpl':'micropro_img.tpl'),array( + + $tpl = 'micropro_img.tpl'; + if($mode === true) + $tpl = 'micropro_txt.tpl'; + if($mode === 'card') + $tpl = 'micropro_card.tpl'; + + return replace_macros(get_markup_template($tpl), array( '$click' => (($contact['click']) ? $contact['click'] : ''), '$class' => $class . (($contact['archived']) ? ' archived' : ''), '$oneway' => (($contact['oneway']) ? true : false), '$url' => $url, '$photo' => $contact['xchan_photo_s'], '$name' => $contact['xchan_name'], + '$addr' => $contact['xchan_addr'], '$title' => $contact['xchan_name'] . ' [' . $contact['xchan_addr'] . ']', + '$network' => sprintf(t('Network: %s'), $contact['xchan_network']) )); } |