<?php
############################################################
# \-\-\-\-\-\-\ AzDG - S C R I P T S /-/-/-/-/-/-/ #
############################################################
# AzDGDatingMedium Version 1.9.3 #
# Written by AzDG (hide@address.com) #
# Created 24/10/02 Last Modified 22/03/06 #
# Scripts Home: http://www.azdg.com #
############################################################
# File name bad.php #
# File purpose Sent bad profiles to admin #
# File created by AzDG <hide@address.com> #
############################################################
include_once 'include/config.inc.php';
include_once 'include/options.inc.php';
include_once 'include/security.inc.php';
include_once 'include/functions.inc.php';
include_once 'templates/'.C_TEMP.'/config.php';
IsSecure(C_BAD);
include_once C_PATH.'/sheader.php';
if(!IsAccess(C_BADSH)) sprintm($w[153]);
if (isset($id)&&is_numeric($id)) {
if(isset($do)) {
if( !isset($reason) || (isset($reason) && trim($reason) == '')) sprintm($w[403]);
$reason = cb($reason);
$sql = mysql_query("SELECT count(id) as total FROM ".C_MYSQL_BAD_PROFILES." WHERE user = '".$id."'") or die(mysql_error());
$trows = mysql_fetch_array($sql);
$total = $trows['total'];
if($total != '0') sprintm($w[154]);
unset($m);
$who = (!is_numeric(get_info('m'))) ? '0' : get_info('m');
mysql_query("INSERT INTO ".C_MYSQL_BAD_PROFILES." VALUES(null,NOW(''),'".ip2int(ip())."','".$who."','".$id."','".$reason."')") or die(mysql_error());
sprintm($w[155]);
} else {
$sql = mysql_query("SELECT count(id) as total FROM ".C_MYSQL_BAD_PROFILES." WHERE user = '".$id."'") or die(mysql_error());
$trows = mysql_fetch_array($sql);
$total = $trows['total'];
if($total != '0') sprintm($w[154]);
define('REPORT_THIS_PROFILE',$w[218]);
define('ENTER_YOUR_REASON',$w[403]);
define('SEND_MESSAGE',$w[170]);
define('ID_VALUE',$id);
if(isset($uname)) define('USER_NAME',cb($uname));
else define('USER_NAME','');
include_once C_PATH.'/templates/'.C_TEMP.'/bad.php';
}
}
include_once C_PATH.'/sfooter.php';
?>