<?php
!defined('IN_MYMPS') && exit('FORBIDDEN');
require MYMPS_DATA."/config.db.php";
require MYMPS_INC."/db.class.php";
require MYMPS_INC."/member.class.php";

/*if(!$member_log->chk_in()){
	@include MYMPS_DATA.'/caches/authcodesettings.php';
	$authcodesettings = $data;
	$data = NULL;
	$gourl = 'do_report';
	include MYMPS_ROOT.'/template/box/login.tpl.php';
	exit;
}*/

$ip 		 = '';
$ip 		 = GetIP();
$report_type = isset($report_type) ? intval($report_type) : '';

if(mymps_count("info_report","WHERE infoid = '$infoid' AND ip = '$ip' AND pubtime > '".mktime(0,0,0)."'") > 0){
	echo "<br><center style=\"color:red\">该信息您已经举报过了 ^_^</center><br>";
	exit;
}
$db->query("INSERT INTO `{$db_mymps}info_report` (report_type,content,infoid,infotitle,ip,pubtime,mobile)VALUES('$report_type','$content','$infoid','$infotitle','$ip','".$timestamp."','$mobile')");
echo "<div style=\"margin:20px 15px 15px 15px\"><font style=\"font-size:14px;color:#42b712\"><h1>感谢您的举报 :)</h1><br />网站管理员会认真核实您反映的情况，并快速处理，谢谢您的举报。</font></div>";
?>