function displayProfileTitle() { $path = System::GetVirtualPath(); $id = $path[1]; $CurrentTenant = Tenant::GetCurrent(); $objUser = $CurrentTenant->GetObject("User"); $thisuser = $objUser->GetInstance(new TenantQueryParameter("URL", $id)); if ($thisuser == null) { return; } ?> <div class="ProfileTitle"> <?php mmo_display_user_badges_by_user($thisuser); ?> <span class="ProfileUserName"><?php echo $thisuser->LongName; ?> </span> <?php if ($action != "customize") { ?> <span class="ProfileControlBox"> <?php if ($CurrentUser != null && $thisuser->ID != $CurrentUser->ID) { if (mmo_has_user_friend_request(null, $thisuser)) { ?> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /Disconnect">Withdraw Friend Request</a> <?php } else { if (mmo_has_user_friend_request($thisuser, $CurrentUser)) { ?> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /Connect/<?php echo mmo_get_user_friendship_auth_key($thisuser, $CurrentUser); ?> ">Confirm Friendship</a> <?php } else { if ($CurrentUser->HasFriend($thisuser)) { ?> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /Disconnect"><?php echo LanguageString::GetByName("friend_disconnect"); ?> </a> <?php } else { ?> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /Connect"><?php echo LanguageString::GetByName("friend_connect"); ?> </a> <?php } } } ?> <form action="<?php echo System::$Configuration["Application.BasePath"]; ?> /Account/Messages/Create" method="POST"> <input type="hidden" name="message_receiver" value="<?php echo $thisuser->ID; ?> " /> <input class="LinkButton" type="submit" value="<?php echo LanguageString::GetByName("message_send"); ?> " /> </form> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /trade/"><?php echo LanguageString::GetByName("resource_trade"); ?> </a> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /block" onclick="/* ReportBlockDialog.Show(); return false; */">Report/Block</a> <?php } if ($thisuser->IsAuthenticated) { ?> <a href="<?php echo System::$Configuration["Application.BasePath"]; ?> /community/members/<?php echo $id; ?> /Customize">Customize Profile</a> <?php } } ?> </span> </div> <?php }
public function Render($comment_base_url = null) { $CurrentUser = User::GetCurrent(); $ParentObjectType = 0; switch (get_class($this)) { case "GroupTopicComment": $ParentObjectType = 1; break; case "JournalEntryComment": $ParentObjectType = 2; break; } ?> <div class="Comment"> <div class="CommentTitle" id="Comment_<?php echo $this->ID; ?> _title"><?php echo $this->Title; ?> </div> <div class="CommentEditor CommentTitle" id="Comment_<?php echo $this->ID; ?> _editor_title"><input id="Comment_<?php echo $this->ID; ?> _editor_title_input" type="text" value="<?php echo $this->Title; ?> " /></div> <div class="CommentContent" id="Comment_<?php echo $this->ID; ?> _content"><?php echo $this->Content; ?> </div> <div class="CommentEditor" id="Comment_<?php echo $this->ID; ?> _editor_content"> <textarea id="Comment_<?php echo $this->ID; ?> _editor_content_input"><?php echo $this->Content; ?> </textarea> </div> <div class="CommentInformation"> <span class="PostedBy"> Posted by <span class="Author"><a href="<?php echo System::ExpandRelativePath("~/community/members/" . $this->Author->ShortName); ?> " target="_blank"><img src="<?php echo System::ExpandRelativePath("~/community/members/" . $this->Author->ShortName . "/images/avatar/thumbnail.png"); ?> " style="height: 32px;" /> <?php mmo_display_user_badges_by_user($this->Author); echo $this->Author->LongName; ?> </a></span> on <span class="Timestamp"><?php echo $this->TimestampCreated; ?> </span> </span> <span class="CommentActions"> <a id="Comment_<?php echo $this->ID; ?> _actions_like" href="#" onclick="CommentManager.SetPopularity(<?php echo $ParentObjectType; ?> , <?php echo $this->ID; ?> , 1); return false;">Like</a> | <a id="Comment_<?php echo $this->ID; ?> _actions_dislike" href="#" onclick="CommentManager.SetPopularity(<?php echo $ParentObjectType; ?> , <?php echo $this->ID; ?> , -1); return false;">Dislike</a> | <a id="Comment_<?php echo $this->ID; ?> _actions_reply" href="#" onclick="CommentManager.Reply(<?php echo $ParentObjectType; ?> , <?php echo $this->ID; ?> ); return false;">Reply</a> <?php if ($this->Author->ID == $CurrentUser->ID) { ?> | <a id="Comment_<?php echo $this->ID; ?> _actions_modify" href="#" onclick="CommentManager.BeginModify(<?php echo $ParentObjectType; ?> , <?php echo $this->ID; ?> ); return false;">Modify</a> | <a id="Comment_<?php echo $this->ID; ?> _actions_delete" href="#" onclick="CommentManager.Delete(<?php echo $ParentObjectType; ?> , <?php echo $this->ID; ?> ); return false;">Delete</a> <?php } ?> </span> </div> </div> <?php }