2 //Profile template for social
6 <div class="social-wrapper">
7 <div><h3><?php echo printSocialName($this->profile['member_id'], false); ?></h3></div>
8 <div class="social-left">
9 <div class="headingbox" style="margin-right:1em;">
10 <h4><?php echo _AT('profile'); ?></h4>
12 <div class="contentbox" style="margin-right:1em;">
13 <?php if ($this->scope=='owner'): ?>
14 <div style="float:right; border:thin #cccccc solid;">
15 <a href="<?php echo url_rewrite(AT_SOCIAL_BASENAME."edit_profile.php");?>"><img src="<?php echo $_base_href.AT_SOCIAL_BASENAME;?>images/edit_profile.gif" alt="<?php echo _AT('edit_profile'); ?>" title="<?php echo _AT('edit_profile'); ?>" border="0"/></a>
19 //TODO: include this in the printSocialProfileImg function itself
20 if (profile_image_exists($this->profile['member_id'])): ?>
21 <a href="get_profile_img.php?id=<?php echo $this->profile['member_id'].SEP ;?>size=o"><?php echo printSocialProfileImg($this->profile['member_id'], 2, false); ?></a>
23 <?php echo printSocialProfileImg($this->profile['member_id'], 2, false); ?>
25 <p><a href="inbox/send_message.php?id=<?php echo $this->profile['member_id']; ?>"><?php echo _AT('send_message'); ?></a></p>
26 <dl class="public-profile">
28 <?php if($this->profile['occupation']){ ?>
29 <dt><?php echo _AT('occupation'); ?></dt><br />
30 <dd><?php echo AT_print($this->profile['occupation'], 'social.profile'); ?></dd>
32 <?php if($this->profile['expertise']){ ?>
33 <dt><?php echo _AT('expertise'); ?></dt><br />
34 <dd><?php echo AT_print($this->profile['expertise'], 'social.profile'); ?></dd>
36 <?php if ($this->relationship==AT_SOCIAL_FRIENDS_VISIBILITY || $this->relationship==AT_SOCIAL_OWNER_VISIBILITY): ?>
37 <?php if($this->profile['email']): ?>
38 <dt><?php echo _AT('email'); ?></dt><br />
39 <dd><?php echo AT_print($this->profile['email'], 'social.profile'); ?></dd>
42 <?php if($this->profile['gender']!='n'){ ?>
43 <dt><?php echo _AT('gender'); ?></dt><br />
44 <dd><?php echo $this->profile['gender']; ?></dd>
46 <?php if($this->profile['dob']!='0000-00-00'){ ?>
47 <dt><?php echo _AT('dob'); ?></dt><br />
48 <dd><?php echo $this->profile['dob']; ?></dd>
50 <?php if($this->profile['phone']){ ?>
51 <dt><?php echo _AT('phone'); ?></dt><br />
52 <dd><?php echo AT_print($this->profile['phone'], 'social.profile'); ?></dd>
54 <?php if($this->profile['country']){ ?>
55 <dt><?php echo _AT('country'); ?></dt><br />
56 <dd><?php echo AT_print($this->profile['country'], 'social.profile'); ?></dd>
58 <?php if($this->profile['postal']){ ?>
59 <dt><?php echo _AT('street_address'); ?></dt><br />
60 <dd><?php echo AT_print($this->profile['postal'], 'social.profile'); ?></dd>
62 <?php if($this->profile['interests']){ ?>
63 <dt><?php echo _AT('interests'); ?></dt><br />
64 <dd><?php echo AT_print($this->profile['interests'], 'social.profile'); ?></dd>
66 <?php if($this->profile['associations']){ ?>
67 <dt><?php echo _AT('associations'); ?></dt><br />
68 <dd><?php echo AT_print($this->profile['associations'], 'social.profile'); ?></dd>
70 <?php if($this->profile['awards']){ ?>
71 <dt><?php echo _AT('awards'); ?></dt><br />
72 <dd><?php echo AT_print($this->profile['awards'], 'social.profile'); ?></dd>
74 <?php if($this->profile['others']){ ?>
75 <dt><?php echo _AT('others'); ?></dt><br />
76 <dd><?php echo AT_print($this->profile['others'], 'social.profile'); ?></dd>
78 <?php if($this->personal['per_weight']){ ?>
79 <dt><?php echo _AT('per_weight'); ?></dt><br />
80 <dd><?php echo AT_print($this->personal['per_weight'], 'social.profile'); ?></dd>
82 <?php if($this->personal['per_height']){ ?>
83 <dt><?php echo _AT('per_height'); ?></dt><br />
84 <dd><?php echo AT_print($this->personal['per_height'], 'social.profile'); ?></dd>
86 <?php if($this->personal['per_hair']){ ?>
87 <dt><?php echo _AT('per_hair'); ?></dt><br />
88 <dd><?php echo AT_print($this->personal['per_hair'], 'social.profile'); ?></dd>
90 <?php if($this->personal['per_eyes']){ ?>
91 <dt><?php echo _AT('per_eyes'); ?></dt><br />
92 <dd><?php echo AT_print($this->personal['per_eyes'], 'social.profile'); ?></dd>
94 <?php if($this->personal['per_ethnicity']){ ?>
95 <dt><?php echo _AT('per_ethnicity'); ?></dt><br />
96 <dd><?php echo AT_print($this->personal['per_ethnicity'], 'social.profile'); ?></dd>
98 <?php if($this->personal['per_languages']){ ?>
99 <dt><?php echo _AT('per_languages'); ?></dt><br />
100 <dd><?php echo AT_print($this->personal['per_languages'], 'social.profile'); ?></dd>
102 <?php if($this->personal['per_disabilities']){ ?>
103 <dt><?php echo _AT('per_disabilities'); ?></dt><br />
104 <dd><?php echo AT_print($this->personal['per_disabilities'], 'social.profile'); ?></dd>
111 <?php if (!empty($this->representation)){ ?>
112 <br /><div class="headingbox" style="margin-right:1em;"><h4><?php echo _AT('representation'); ?></h4></div>
113 <div class="contentbox" style="margin-right:1em;">
115 <?php foreach($this->representation as $row=>$value){ ?>
116 <dl class="public-profile">
117 <dt><?php echo _AT('name') . ':' ?></dt> <br /><dd> <?php echo AT_print($value['rep_name'], 'social.profile'); ?></dd>
118 <dt><?php echo _AT('title') . ': ' ?></dt> <br /><dd> <?php echo AT_print($value['rep_title'], 'social.profile'); ?></dd>
119 <dt><?php echo _AT('phone') . ':' ?></dt><br /> <dd> <?php echo AT_print($value['rep_phone'], 'social.profile');?></dd>
120 <dt><?php echo _AT('email') . ': ' ?></dt><br /> <dd> <?php echo AT_print($value['rep_email'], 'social.profile'); ?></dd>
121 <dt><?php echo _AT('street_address') . ': ' ?></dt> <br /><dd> <?php echo AT_print($value['rep_address'], 'social.profile'); ?></dd>
128 <?php if (!empty($this->contact)){ ?>
129 <br /><div class="headingbox" style="margin-right:1em;"><h4><?php echo _AT('alt_contact'); ?></h4></div>
130 <div class="contentbox" style="margin-right:1em;">
132 <?php foreach($this->contact as $row=>$value){ ?>
133 <dl class="public-profile">
134 <dt><?php echo _AT('name') . ':' ?></dt> <br /><dd> <?php echo AT_print($value['con_name'], 'social.profile'); ?></dd>
135 <dt><?php echo _AT('phone') . ':' ?></dt> <br /><dd> <?php echo AT_print($value['con_phone'], 'social.profile');?></dd>
136 <dt><?php echo _AT('email') . ': ' ?></dt><br /> <dd> <?php echo AT_print($value['con_email'], 'social.profile'); ?></dd>
137 <dt><?php echo _AT('street_address') . ': ' ?></dt><br /> <dd> <?php echo AT_print($value['con_address'], 'social.profile'); ?></dd>
149 <div class="social-right">
150 <?php if (PrivacyController::validatePrivacy(AT_SOCIAL_PROFILE_EDUCATION, $this->relationship, $this->prefs)): ?>
151 <?php if (!empty($this->education)){ ?>
153 <div class="headingbox"><h5><?php echo _AT('training_and_education'); ?></h5></div>
154 <div class="contentbox">
155 <table class="data static">
157 <th> <?php echo _AT('institution'); ?></th>
158 <th> <?php echo _AT('degrees'); ?></th>
159 <th> <?php echo _AT('year'); ?></th>
163 foreach($this->education as $edu){
164 echo '<tr><td>'.AT_print($edu['university'], 'social.profile').'</td>';
165 echo '<td>'.AT_print($edu['degree'].'/'.$edu['field'], 'social.profile').'</td>';
166 echo '<td>'.AT_print($edu['from'].'-'.$edu['to'], 'social.profile').'</td></tr>';
176 <?php if (PrivacyController::validatePrivacy(AT_SOCIAL_PROFILE_POSITION, $this->relationship, $this->prefs)): ?>
178 <?php if (!empty($this->position)){ ?>
180 <div class="headingbox"><h5><?php echo _AT('credits_and_work_experience'); ?></h5></div>
181 <div class="contentbox">
182 <table class="data static">
184 <th><?php echo _AT('company'); ?></th>
185 <th><?php echo _AT('position'); ?></th>
186 <th><?php echo _AT('year'); ?></th>
190 foreach($this->position as $pos){
191 echo '<tr><td>'.AT_print($pos['company'], 'social.profile').'</td>';
192 echo '<td>'.AT_print($pos['title'], 'social.profile').'</td>';
193 echo '<td>'.AT_print($pos['from'].'-'.$pos['to'], 'social.profile').'</td></tr>';
202 <?php if (PrivacyController::validatePrivacy(AT_SOCIAL_PROFILE_MEDIA, $this->relationship, $this->prefs)): ?>
204 <?php if (!empty($this->websites)): ?>
205 <div class="headingbox"><h5><?php echo _AT('websites'); ?></h5></div>
206 <div class="contentbox">
207 <table class="data static">
209 <th><?php echo _AT('site_name'); ?></th>
210 <th><?php echo _AT('url'); ?></th>
214 foreach($this->websites as $sites){
215 $is_http = preg_match("/^http/", $sites['url']);
217 $sites['url'] = 'http://' . $sites['url'];
219 echo '<tr><td>'.AT_print($sites['site_name'], 'social.profile').'</td>';
220 echo '<td><a href="'.$sites['url'].'" target="user_profile_site">'.$sites['url'].'</a></td></tr>';
230 <?php if (PrivacyController::validatePrivacy(AT_SOCIAL_PROFILE_STATUS_UPDATE, $this->relationship, $this->prefs)): ?>
231 <div class="headingbox">
232 <h5><?php echo _AT('activities'); ?></h5></div>
233 <div class="contentbox" id="activity">
234 <?php if(!empty($this->activities)): ?>
237 foreach($this->activities as $id=>$activity):
239 * harris @may 26, 2009
240 * Would be nice to use this, but we will have to change "has" to "have" for _AT('you')
242 if ($_SESSION['member_id']== $this->profile['member_id']){
243 echo '<li>'._AT('you');
244 echo ' '.$activity.' ';
245 echo '<a href="'.url_rewrite(AT_SOCIAL_BASENAME.'sprofile.php?delete='.$id).'"><img src="'.$_base_href.AT_SOCIAL_BASENAME.'images/b_drop.png" alt="'._AT('remove').'" title="'._AT('remove').'" border="0" /></a></li>';
247 echo '<li>'.printSocialName($this->profile['member_id']).' '.$activity.'</li>';
251 <li><?php echo $activity['created_date']. ' - '. printSocialName($activity['member_id']).' '. $activity['title']; ?></li>
255 <?php echo _AT('no_activities'); ?>
260 <?php if (PrivacyController::validatePrivacy(AT_SOCIAL_PROFILE_CONNECTION, $this->relationship, $this->prefs)): ?>
261 <div class="headingbox">
262 <h5><?php echo _AT('connections'); ?></h5>
264 <div class="contentbox">
265 <?php if (sizeof($this->friends)>0):
266 foreach($this->friends as $friend_id): ?>
267 <div style="float:left; margin-left:1em;">
268 <?php echo printSocialProfileImg($friend_id); ?><br/>
269 <?php echo printSocialName($friend_id); ?>
273 echo _AT('no_friends');
277 <?php if (isset($this->mutual_friends)): ?>
278 <div class="headingbox">
279 <h5><?php echo _AT('mutual_connections'); ?></h5>
281 <div class="contentbox">
282 <?php foreach($this->mutual_friends as $friend_id): ?>
283 <div style="float:left; margin-left:1em;">
284 <?php echo printSocialProfileImg($friend_id); ?><br/>
285 <?php echo printSocialName($friend_id); ?>
289 <?php endif; //this->mutual_friends != empty ?>
296 <div style="clear:both;"></div>