Fixing a small css issue in the user class.
[elgg.git] / units / admin / admin_contentflags.php
blobb034ae29a60a8404a2f30c2807e0602643bbc244
1 <?php
2 global $USER,$CFG;
3 // Content flag list
5 if (logged_on && user_flag_get("admin", $USER->ident)) {
7 $run_result .= "<p>" . __gettext("The following pages have been flagged as having obscene or inappropriate content. They are ordered by number of complaints.") . "</p>";
8 $run_result .= "<p>" . __gettext("To view the pages in question, click the following links. To remove the flags, for example if the flag is a false positive or if you've deleted the offending content, check the appropriate box and click the 'delete' button below.") . "</p>";
10 $run_result .= "<form action=\"\" method=\"post\">";
12 if ($flags = get_records_sql('SELECT DISTINCT url,count(ident) AS totalflags
13 FROM '.$CFG->prefix.'content_flags
14 GROUP BY url ORDER BY totalflags desc')) {
15 $run_result .= templates_draw(array(
16 'context' => 'adminTable',
17 'name' => "&nbsp;",
18 'column1' => "<b>" . __gettext("Page URL") . "</b>",
19 'column2' => "<b>" . __gettext("Number of objections") . "</b>"
23 foreach($flags as $flag) {
25 $run_result .= templates_draw(array(
26 'context' => 'adminTable',
27 'name' => "<input type=\"checkbox\" name=\"remove[]\" value=\"" . $flag->url . "\" />",
28 'column1' => "<a href=\"" . $flag->url . "\" target=\"_blank\">" . $flag->url . "</a>",
29 'column2' => $flag->totalflags
35 $run_result .= templates_draw(array(
36 'context' => 'adminTable',
37 'name' => "&nbsp;",
38 'column1' => "<input type=\"submit\" value=\"".__gettext("Remove flag(s)")."\" />",
39 'column2' => "<input type=\"hidden\" name=\"action\" value=\"content:flags:delete\" />"
43 } else {
44 $run_result .= "<p>" . __gettext("No content flags were found at present.") . "</p>";
47 $run_result .= "</form>";