public function PrintAuthorName() { if ($this->AuthorID == 'admin' && empty($this->AuthorName)) { $this->AuthorName = 'Anonymous'; } if (isPowerUser()) { OpenTag('a', 'href="/profile/' . $this->AuthorID . '"'); } OpenTag('strong'); if (strpos($this->AuthorName, '#') === false) { PrintText($this->AuthorName); } else { $tripchunks = Tripcode($this->AuthorName); PrintText(htmlentities($tripchunks[0])); OpenTag('span', 'class="tripcode"'); PrintText('!' . htmlentities($tripchunks[1])); CloseTag(); } CloseTag(); if (isPowerUser()) { CloseTag(); } if (($this->Flags & REPLY_ADMIN_POST) == REPLY_ADMIN_POST || $this->AuthorID == 'admin') { echo '<span class="admin_name">##<a href="/' . ADMIN_NAME . '">' . ADMIN_NAME . '</a></span>'; } else { if (($this->Flags & REPLY_MOD_POST) == REPLY_MOD_POST) { echo '<span class="admin_name">##<a href="/' . MOD_NAME . '">' . MOD_NAME . '</a></span>'; } } PrintText(' '); }
$columns = array('Doing', 'Poster', 'Last sign of life ▼'); $table->define_columns($columns, 'Doing'); $table->add_td_class('Poster', 'minimal'); $table->add_td_class('Last sign of life ▼', 'minimal'); $i = 0; // Array key based off $actions = array('advertise' => 'Inquiring about advertising.', 'statistics' => 'Looking at board statistics.', 'hot_topics' => 'Looking at the hottest topics.', 'bulletins' => 'Reading latest bulletins.', 'bulletins_old' => 'Reading latest bulletins.', 'folks' => 'Looking at what other people are doing.', 'topics' => 'Looking at older topics.', 'dashboard' => 'Modifying their dashboard', 'latest_replies' => 'Looking at latest replies.', 'latest_bumps' => 'Checking out latest bumps.', 'latest_topics' => 'Checking out latest topics.', 'search' => 'Searching for a topic.', 'stuff' => 'Looking at stuff.', 'history' => 'Looking at post history.', 'failed_postings' => 'Looking at post failures.', 'watchlist' => 'Checking out their watchlist.', 'restore_id' => 'Logging in.', 'new_topic' => 'Creating a new topic.', 'nonexistent_topic' => 'Trying to look at a non-existant topic.', 'topic' => "Reading in topic: <strong><a href=\"/topic/{$action_id}\">{$headline}</a></strong>", 'replying' => "Replying to topic: <strong><a href=\"/topic/{$action_id}\">{$headline}</a></strong>", 'topic_trivia' => "Reading <a href=\"/trivia_for_topic/{$action_id}\">trivia for topic</a>: <strong><a href=\"/topic/{$action_id}\">{$headline}</a></strong>", 'banned' => 'Being banned.'); while (list($action, $action_id, $uid, $age, $headline) = $res->FetchRow()) { // Maximum amount of actions to be shown (100 by default) if (++$i == 100) { break; } if ($uid == $_SESSION['UID']) { $uid = 'You!'; } else { if (isPowerUser()) { $uid = '<a href="/profile/' . $uid . '">' . $uid . '</a>'; } else { $uid = '?'; } } $bump = calculate_age($age, $_SERVER['REQUEST_TIME']); $headline = htmlspecialchars($headline); $action = $actions[$action]; // Unknown or unrecorded actions are bypassed if ($action == null) { continue; } // Repeated actions are listed as (See above) if ($action == $old_action) { $temp = '<span class="unimportant">(See above)</span>';
function isEditable() { return $this->AuthorID == $_SESSION['UID'] && TIME_TO_EDIT == 0 || $this->AuthorID == $_SESSION['UID'] && $_SERVER['REQUEST_TIME'] - $this->Time < TIME_TO_EDIT || isPowerUser(); }
<?php require('includes/header.php'); //DB::ToggleDebug(); if(!isPowerUser()) Output::HardError("You are not wise enough."); Output::Assign('sidebar',$sidebar); Output::$tpl->display('dashhead.tpl.php'); switch(Path::FetchIndex(0)) { case 'powerusers': update_activity('admins'); if(!$User->isAdmin()) Output::HardError('You are not wise enough.'); if($_POST['form_sent'] && check_token()) { //var_dump($_POST); exit; $lvl=$User->getMACLevel(); if(!empty($_POST['add_sysop'])) { if($lvl<999) die('No.'); DB::Execute('UPDATE {P}UserSettings SET usrFlags=usrFlags|'.PERMISSION_SYSOP.' WHERE usrID='.DB::Q($_POST['add_sysop'])); $_SESSION['notice'].='<li>'.$_POST['add_sysop'].' added as a '.ADMIN_NAME.'.</li>'; } if(!empty($_POST['add_mod'])) { if($lvl<100) die('No.');
<li> <a href="<?php echo rel2Abs('/new_reply/' . $_GET['id'] . '/cite_reply/' . $reply->ID); ?> "> Cite </a> </li> </ul> </div> <? // Store information for the next round. $c++; $prevtime=$reply->Time; endforeach; if(isPowerUser()):?> <h2>UID Dump</h2> <? $uidt=new TablePrinter('tblUIDs'); $uidt->DefineColumns(array('UID','Names'),'Names'); foreach($this->topic->UIDs as $uid=>$names) { if($uid!='admin') $uid=sprintf('<a href="%1$sprofile/%2$s">%2$s</a>',THISURL,$uid); $uidt->Row(array($uid,implode(', ',$names))); } echo $uidt; ?> <?endif;?> <ul class="menu">