Esempio n. 1
0
function commenttable($rows) {
	global $CURUSER, $HTTP_SERVER_VARS, $sign_dir;
	begin_main_frame();
	begin_frame();
	$count = '0';
	foreach ($rows as $row) {
		echo '<p class="sub">#'.$row['id'].' eftir ';
		if (isset($row['username'])) {
			$title = $row['title'];
			if (empty($title))
				$title = get_user_class_name($row['class']);
			else
				$title = htmlspecialchars($title);
		echo '<a name="comm"'.$row['id'].' href="userdetails.php?id='.$row['user'].'"><b>'.htmlspecialchars($row['username']).'</b></a>'. ($row['donor'] == 'yes' ? '<img src="/pic/star.gif" alt="Donor">' : '').($row['warned'] == 'yes' ? '<img src="'.'/pic/warned.gif" alt="Viðvörun" />' : '').' ('.$title.')'."\n";
		} else
			echo '<a name="comm'.$row['id'].'"><i>(munaðarlaus)</i></a>'."\n";
		echo ' þann '.$row['added'].' GMT'.(get_user_class() >= UC_MODERATOR ? '- [<a href="deletecomment.php?id='.$row['id'].'">Eyða</a>]' : '') . '</p>'."\n";
		$avatar = ($CURUSER['avatars'] == 'yes' ? htmlspecialchars($row['avatar']) : '');
		if (empty($avatar))
			$avatar = '/pic/default_avatar.gif';
		begin_table(true);
		echo '<tr valign="top">'."\n";
		echo '<td align="center" width="150px" style="padding:0px"><img width="150px" src="'.$avatar.'"></td>'."\n";
		echo '<td class="text">'.format_comment($row['text']);
		if($CURUSER['undirskrift'] === '1')
			echo signiture($row['user']);
		echo '</td>'."\n".'</tr>'."\n";
		end_table();
	}
	end_frame();
	end_main_frame();
}
Esempio n. 2
0
if($lengd > 0) {
  if(get_user_class() >= UC_MODERATOR) { $classi .= ' (' . $user['title'] . ')'; }
  else { $classi = $user['title']; }
}
print("<tr><td class=rowhead>Staða</td><td align=left>$classi</td></tr>\n");
print("<tr><td class=rowhead>Torrent athugasemdir</td>");
if ($torrentcomments && ($user["id"] == $CURUSER["id"] || get_user_class() >= UC_MODERATOR))
	print("<td align=left><a href=userhistory.php?action=viewcomments&id=$id>$torrentcomments</a></td></tr>\n");
else
	print("<td align=left>$torrentcomments</td></tr>\n");
print("<tr><td class=rowhead>Spjallpóstar</td>");
if ($forumposts && (($user["class"] >= UC_POWER_USER && $user["id"] == $CURUSER["id"]) || get_user_class() >= UC_MODERATOR))
	print("<td align=left><a href=userhistory.php?action=viewposts&id=$id>$forumposts</a></td></tr>\n");
else
	print("<td align=left>$forumposts</td></tr>\n");
echo '<tr><td class=rowhead>Undirskrift</td><td align=left>'.signiture($user['id']).'</td></tr>'."\n";
if(get_user_class() >= UC_MODERATOR || $CURUSER['id'] == $user['id']) {
	if (isset($torrents))
	  print("<tr valign=top><td class=rowhead>Innsend torrent</td><td align=left>$torrents</td></tr>\n");
	if (isset($seeding))
	  print("<tr valign=top><td class=rowhead>Er að deila</td><td align=left>$seeding</td></tr>\n");
	if (isset($leeching))
	  print("<tr valign=top><td class=rowhead>Skráarsuga á</td><td align=left>$leeching</td></tr>\n");
	include("who_invited.php");
}
if ($user["info"])
 print("<tr valign=top><td align=left colspan=2 class=text bgcolor=#F4F4F0>" . format_comment($user["info"]) . "</td></tr>\n");

if ($CURUSER["id"] != $user["id"])
	if (get_user_class() >= UC_MODERATOR)
  	$showpmbutton = 1;
Esempio n. 3
0
			$body .= "<p><font size=1 class=small>Síðast breytt af <a href=userdetails.php?id=$arr[editedby]><b>$arr2[username]</b></a> þann $arr[editedat] GMT</font></p>\n";
		}
	}


      echo '<tr valign="top"><td width="150px" align="center" style="padding: 0px">' .
        (isset($avatar) ? "<img width=150 src=\"$avatar\">" : "");
	if($CURUSER['class'] >= UC_MODERATOR && $avadult === 'yes')
		echo '<br />[Merkt sem særandi]';
	elseif($CURUSER['class'] >= UC_MODERATOR && $avadult === 'no')
		echo '<br />[Merkt sem viðeigandi]';
	if($class >= UC_MODERATOR)
		echo '<br /><img src="/pic/stjornandi.png" />';
	echo '</td><td class="comment">'.$body;
	if($CURUSER['undirskrift'] == '1')
		echo signiture($posterid);
	echo '</td></tr>'."\n";

      end_table();
    }

    //------ Mod options

	  if (get_user_class() >= UC_MODERATOR)
	  {
	    attach_frame();

	    $res = mysql_query("SELECT id,name,minclasswrite FROM forums ORDER BY name") or sqlerr(__FILE__, __LINE__);
	    print("<table border=0 cellspacing=0 cellpadding=0>\n");

	    print("<form method=post action=?action=setsticky>\n");