<?php
/**
 * @version        $Id: guestbook.inc.php 1 10:06 2010-11-10 tianya $
 * @package        DedeCMS.Site
 * @copyright      Copyright (c) 2007 - 2010, DesDev, Inc.
 * @license        http://help.dedecms.com/usersguide/license.html
 * @link           http://www.dedecms.com
 */
require(dirname(__FILE__).'/../../include/common.inc.php');
require_once(DEDEINC."/filter.inc.php");
if(empty($gotopagerank)) $gotopagerank='';
require_once(DEDEINC."/memberlogin.class.php");
$cfg_ml = new MemberLogin(-1);

//設置為 0,表示留言需要審核
//如果設置為 1 ,則留言不需要審核就能顯示
if($cfg_feedbackcheck=='Y') $needCheck = 0;
else $needCheck = 1;

//是否是會員或管理員
if($cfg_ml->IsLogin())
{
    $g_isadmin = ($cfg_ml->fields['matt'] >= 10);
    $g_mid = $cfg_ml->M_ID;
    $g_name = $cfg_ml->M_UserName;
}
else
{
    $g_isadmin = FALSE;
    $g_mid = 0;
    $g_name = '';
}

function GetIsCheck($ischeck,$id)
{
    if($ischeck==0) return "<br><a href='guestbook.php?action=admin&job=check&id=$id' style='color:red'>[審核]</a>";
    else return '';
}