示例#1
0
 public static function getInstance()
 {
     if (null == self::$instance) {
         self::$instance = new KommentariUtils();
     }
     return self::$instance;
 }
示例#2
0
文件: index.php 项目: vberzsin/2014
function deleteComment($app)
{
    $session = Session::getInstance();
    $user = User::getInstance();
    $kommentariUtils = KommentariUtils::getInstance();
    $utils = Utils::getInstance();
    $cid = $utils->iStr($app->request()->post('cid'), 255);
    $res = $kommentariUtils->deleteComment($cid);
    $err = false == $res ? '' : $session->flushError();
    $res = false == $res ? 'false' : 'ok';
    $res = array('req' => 'deleteComment', 'res' => $res, 'cid' => $cid);
    return $res;
}
示例#3
0
 public function __construct()
 {
     User::getInstance()->auth('*****@*****.**', 'tenant');
     $this->kommentariUtils = KommentariUtils::getInstance();
     $this->session = Session::getInstance();
 }