aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-07-03 22:51:49 -0700
committerfriendica <info@friendica.com>2013-07-03 22:51:49 -0700
commit6f390330ff45c2b636a20c2c4e32e70c74523d6a (patch)
treec841cee3a00b87293b8b2295e1dcaeaa5d24cf72 /include
parentfbdee83dca4aa9e5d66488f32121d8c62e378316 (diff)
downloadvolse-hubzilla-6f390330ff45c2b636a20c2c4e32e70c74523d6a.tar.gz
volse-hubzilla-6f390330ff45c2b636a20c2c4e32e70c74523d6a.tar.bz2
volse-hubzilla-6f390330ff45c2b636a20c2c4e32e70c74523d6a.zip
nearly ready for the output template
Diffstat (limited to 'include')
-rw-r--r--include/profile_advanced.php21
1 files changed, 21 insertions, 0 deletions
diff --git a/include/profile_advanced.php b/include/profile_advanced.php
index f008d1c8f..e113e019d 100644
--- a/include/profile_advanced.php
+++ b/include/profile_advanced.php
@@ -80,9 +80,30 @@ function advanced_profile(&$a) {
if($txt = prepare_text($a->profile['education'])) $profile['education'] = array( t('School/education:'), $txt );
+ $r = q("select * from obj left join term on obj_obj = term_hash where term_hash != '' and obj_page = '%s' and uid = %d and obj_type = %d
+ order by obj_verb, term",
+ dbesc($a->profile['profile_guid']),
+ intval($a->profile['profile_uid']),
+ intval(TERM_OBJ_THING)
+ );
+
+ $things = null;
+
+ if($r) {
+ $things = array();
+ foreach($r as $rr) {
+ if(! $things[$rr['obj_verb']])
+ $things[$rr['obj_verb']] = array();
+ $things[$rr['obj_verb']][] = array('term' => $rr['term'],'url' => $rr['url'],'img' => $rr['imgurl']);
+ }
+ }
+
+ logger('mod_profile: things: ' . print_r($things,true), LOGGER_DATA);
+
return replace_macros($tpl, array(
'$title' => t('Profile'),
'$profile' => $profile,
+ '$things' => $things
));
}