2 // Note: This file is included from the library/Vanilla/Vanilla.Control.Account.php class.
4 echo '<div id="AccountProfile">';
6 if (ForceIncomingBool('Success',0)) echo '<div id="Success">'.$this->Context
->GetDefinition('ChangesSaved').'</div>';
7 $this->Render_Warnings();
9 echo '<ul class="vcard">';
11 $this->CallDelegate('PreUsernameRender');
13 if ($this->User
->DisplayIcon
!= '') {
14 echo '<li class="ProfileTitle WithIcon clearfix">
15 <div class="ProfileIcon" style="background-image:url(\''.$this->User
->DisplayIcon
.'\')"> </div>';
17 echo '<li class="ProfileTitle clearfix">';
19 echo '<h2>'.$this->User
->Name
.'</h2>
20 <p>'.$this->User
->Role
.'</p>
22 if ($this->User
->RoleDescription
!= '') echo('<li class="Tagline">'.$this->User
->RoleDescription
.'</li>');
23 if ($this->User
->Picture
!= "" && $this->User
->Permission('PERMISSION_HTML_ALLOWED')) echo "<li class=\"Picture\" style=\"background-image: url('".$this->User
->Picture
."');\"> </li>";
25 $this->CallDelegate('PostPictureRender');
27 if ($this->Context
->Configuration
['USE_REAL_NAMES'] && ($this->User
->ShowName ||
$this->Context
->Session
->User
->Permission('PERMISSION_EDIT_USERS'))) {
29 <h3>'.$this->Context
->GetDefinition('RealName').'</h3>
30 <p class="fn">'.ReturnNonEmpty($this->User
->FullName
).'</p>
34 <h3>'.$this->Context
->GetDefinition('Email').'</h3>
36 .(($this->Context
->Session
->UserID
> 0 && $this->User
->UtilizeEmail
) ?
37 GetEmail($this->User
->Email
) : $this->Context
->GetDefinition('NA')).'</p>
40 <h3>'.$this->Context
->GetDefinition('AccountCreated').'</h3>
41 <p>'.TimeDiff($this->Context
, $this->User
->DateFirstVisit
, mktime()).'</p>
44 <h3>'.$this->Context
->GetDefinition('LastActive').'</h3>
45 <p>'.TimeDiff($this->Context
, $this->User
->DateLastActive
, mktime()).'</p>
48 <h3>'.$this->Context
->GetDefinition('VisitCount').'</h3>
49 <p>'.$this->User
->CountVisit
.'</p>
52 <h3>'.$this->Context
->GetDefinition('DiscussionsStarted').'</h3>
53 <p>'.$this->User
->CountDiscussions
.'</p>
56 <h3>'.$this->Context
->GetDefinition('CommentsAdded').'</h3>
57 <p>'.$this->User
->CountComments
.'</p>
60 $this->CallDelegate('PostBasicPropertiesRender');
62 if ($this->Context
->Session
->User
->Permission('PERMISSION_IP_ADDRESSES_VISIBLE')) {
64 <h3>'.$this->Context
->GetDefinition('LastKnownIp').'</h3>
65 <p>'.$this->User
->RemoteIp
.'</p>
69 if (count($this->User
->Attributes
) > 0) {
70 $AttributeCount = count($this->User
->Attributes
);
71 for ($i = 0; $i < $AttributeCount; $i++
) {
72 $CssClass = (strpos($this->User
->Attributes
[$i]['Value'], 'http://') == 0 && strpos($this->User
->Attributes
[$i]['Value'], 'http://') !== false) ?
'url' : '';
74 <h3>'.htmlspecialchars($this->User
->Attributes
[$i]['Label']).'</h3>
75 <p>'.FormatHyperlink(htmlspecialchars($this->User
->Attributes
[$i]['Value']), 1, '', $CssClass).'</p>
80 $this->CallDelegate('PostAttributesRender');
84 <div id="AccountHistory">';
86 $this->CallDelegate('PostProfileRender');