XOOPS  2.6.0
system.php
Go to the documentation of this file.
1 <?php
21 {
27  public function userPosts($uid)
28  {
29  $comments = Comments::getInstance(); //need this here to init constants
30  $criteria = new CriteriaCompo();
31  $criteria->add(new Criteria('status', COMMENTS_ACTIVE));
32  $criteria->add(new Criteria('uid', $uid));
33  return Comments::getInstance()->getHandlerComment()->getCount($criteria);
34  }
35 
39  public function waiting()
40  {
41  $comments = Comments::getInstance(); //need this here to init constants
42  $criteria = new CriteriaCompo(new Criteria('status', COMMENTS_PENDING));
43  $ret = array();
44  if ($count = $comments->getHandlerComment()->getCount($criteria)) {
45  $ret['count'] = $count;
46  $ret['name'] = Xoops::getInstance()->getHandlerModule()->getBydirname('comments')->getVar('name');
47  $ret['link'] = Xoops::getInstance()->url('modules/comments/admin/main.php');
48  }
49  return $ret;
50  }
51 
52  public function backend($limit)
53  {
54  return array();
55  }
56 
66  public function userMenus()
67  {
68  // TODO: Implement userMenus() method.
69  }
70 }
static getInstance()
Definition: Xoops.php:160
static getInstance()
Definition: helper.php:46
if(!$xoops->isUser()) $uid
Definition: index.php:31
$comments
Definition: main.php:48
$limit
Definition: findusers.php:202
$criteria