-
Notifications
You must be signed in to change notification settings - Fork 0
/
profile.tmpl.php
81 lines (73 loc) · 2.85 KB
/
profile.tmpl.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<?php
/************************************************************************/
/* ATutor */
/************************************************************************/
/* Copyright (c) 2002-2008 by Greg Gay, Joel Kronenberg & Heidi Hazelton*/
/* Adaptive Technology Resource Centre / University of Toronto */
/* http://atutor.ca */
/* */
/* This program is free software. You can redistribute it and/or */
/* modify it under the terms of the GNU General Public License */
/* as published by the Free Software Foundation. */
/************************************************************************/
// $Id: edit.php 3111 2005-01-18 19:32:00Z joel $
global $display_name_formats, $moduleFactory, $db, $_modules;
?>
<div class="input-form">
<div class="row">
<p><a href="inbox/send_message.php?id=<?php echo $this->row['member_id']; ?>"><?php echo _AT('send_message'); ?></a></p>
<dl id="public-profile">
<?php $mod = $moduleFactory->getModule('_standard/profile_pictures');
if ($mod->isEnabled() === TRUE): ?>
<dt><?php echo _AT('picture'); ?></dt>
<dd><?php if (profile_image_exists($this->row['member_id'])): ?>
<?php
//run a check to see if any personal album exists, if not, create one.
$sql = 'SELECT * FROM '.TABLE_PREFIX.'pa_albums WHERE member_id='.$this->row['member_id'].' AND type_id='.AT_PA_TYPE_PERSONAL;
$result = mysql_query($sql, $db);
if ($result){
$row = mysql_fetch_assoc($result); //album info.
$aid = $row['id'];
}
if (in_array('mods/_standard/photos/index.php', $_modules)){
$img_link = AT_PA_BASENAME.'albums.php?id='.$aid;
} else {
$img_link = 'get_profile_img.php?id='.$this->row['member_id'].SEP.'size=o';
}
?>
<a href="<?php echo $img_link ?>"><?php print_profile_img($this->row['member_id'], 2); ?></a>
<?php else: ?>
<?php echo _AT('none'); ?>
<?php endif; ?>
</dd>
<?php endif; ?>
<dt><?php echo _AT('email'); ?></dt>
<dd>
<?php if($this->row['private_email']): ?>
<?php echo _AT('private'); ?>
<?php else: ?>
<a href="mailto:<?php echo $this->row['email']; ?>"><?php echo $this->row['email']; ?></a>
<?php endif; ?>
</dd>
<dt><?php echo _AT('web_site'); ?></dt>
<dd>
<?php if ($this->row['website']) {
echo '<a href="'.htmlspecialchars($this->row['website'], ENT_COMPAT, "UTF-8").'">'.AT_print($this->row['website'], 'members.website').'</a>';
} else {
echo '--';
} ?>
</dd>
<dt><?php echo _AT('phone'); ?></dt>
<dd>
<?php if ($this->row['phone']) {
echo $this->row['phone'];
} else {
echo '--';
}
?>
</dd>
<dt><?php echo _AT('status'); ?></dt>
<dd><?php echo $this->status; ?></dd>
</dl>
</div>
</div>