Wikka Mod 036

Type: Feature Addition

Credit:

WackoWiki


Modified the lastusers action from WackoWiki to work with Wikka and added the table formatting. -- JsnX

<?php

if ($stat===0) $limit = 1000;
else $limit = 100;

if (!$max || $limit<$max)
  $max = $limit;

$last_users = $this->LoadAll("select name, signuptime from ".$this->config["table_prefix"]."users order by signuptime desc limit ".(int)$max);

$htmlout = "<table width=\"50%\" border=\"0\" cellpadding=\"3%\">\n".
  "  <tr>\n".
    "   <th><u>Name</u></td>\n".
    "   <th><u>Owned Pages</u></td>\n".
    "   <th><u>Signup Date/Time</u></td>\n".
  "  </tr>\n";

foreach($last_users as $user)
{
 $htmlout .= "  <tr>\n";
 if ($stat!=="0") $num = $this->LoadSingle("select count(*) as n from ".$this->config["table_prefix"]."pages where owner='".$user["name"]."' AND latest = 'Y' AND comment_on = ''");
 $htmlout .= "  <td>".$this->Link($user["name"])."</td>\n   <td>".($stat!=="0"?" . . . . . (".$num["n"].")":"")."</td>\n    <td>(".$user["signuptime"].")</td>\n";
 $htmlout .= "  </tr>\n";
}

$htmlout .= "</table>\n";

print($htmlout);

?>



Lastest users....
Recently registered users
Username Owned pages Signup date/time
OeMunoz 2 (2016-12-06 18:10:58)
Onion 0 (2015-02-18 18:43:37)
RamonitaifDumololb 0 (2014-12-25 13:47:09)
VinceliEscamillath 0 (2014-12-25 13:42:32)
KeishayuJuergensxx 0 (2014-12-25 13:23:00)
RufusrfRochati 0 (2014-12-25 13:18:04)
DenisejnSmythjo 0 (2014-12-24 17:42:03)
TerrihjBirchellig 0 (2014-12-24 17:22:21)
YvettesrLeathermanej 0 (2014-12-12 23:45:57)
KareemwmArmytagekt 0 (2014-12-12 20:33:27)
There are no comments on this page.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki