<?php
############################################
### Этот скрипт написан для Wap-Motor 18 ###
###Автор скрипта Dred#######################
###ICQ: 757041##############################
###Сайт: http://nmn.webhop.net##############
###Желающие могут подкинуть деньжат#########
###Z840880492902############################
###R852036927651############################
############################################
require_once"../../template/start.php";require_once"../../template/regglobals.php";require_once"../../template/config.php";require_once"../../template/siti_conf.php";require_once"../../template/functions.php";require_once"../../template/antidos.php";require_once"../../template/cookies.php";require_once"../../template/gzip.php";require_once"../../template/header.php";require_once"../../template/referer.php";include_once"../../themes/$config_themes/index.php";include_once"../../template/isset.php";if (isset ($_GET['msg']) or isset ($_GET['name'])){header ("Location: index.php?no&".SID); exit;}$text = @file("../../local/profil/$log.$prof"); if ($text!=""){$udata = explode(":||:",$text[0]);$provlog=trim($udata[0]);$provpar=trim($udata[1]);}if ($_SESSION['log']!="" && md5($_SESSION['par'])!="" && md5($_SESSION['par'])==$provpar && $_SESSION['log']==$provlog ) {$name=$log;}else{if($config_bookadds=="1"){$name=$config_guestsuser;}}$date=date("d.m.y");$time=date("H:i"); $str=strlen(trim($msg));if($msg=="" || $str<6 || $name==""){header ("Location: index.php?isset=posts&".SID); exit;}if($config_floodstime > 0){if(flooder($ip, $php_self) == TRUE ){header ("Location: index.php?isset=antiflood&".SID); exit;}$flood_file = fopen(BASEDIR."local/flood.dat", "a+");flock ($flood_file,LOCK_EX);fputs ($flood_file,"$time|$ip|$php_self|\r\n");fflush($flood_file);flock ($flood_file,LOCK_UN);fclose($flood_file); }$brow=check($brow);$msg=wordwrap($msg,150,' ',1);$msg=substr($msg,0,1200);$msg=check($msg);$name=check($name);$msg=preg_replace ("|[\r\n]+|si","<br>",$msg);if($trans=="y"){$msg=transliter($msg);}$msg = antimat($msg);$msg = smiles($msg);$text=$msg.'|'.$name.'|'.$date.'|'.$time.'|'.$brow.'|'.$ip.'||';$text=str_replace("\r\n", "", $text);$fp=fopen("../../local/bar.dat","a+");flock ($fp,LOCK_EX);fputs($fp,"$text\r\n");flock ($fp,LOCK_UN);fclose($fp);@chmod("$fp", 0666); $file=file("../../local/bar.dat"); $i = count($file);if ($i>=$config_maxpostbook) {$fp=fopen("../../local/bar.dat","w");flock ($fp,LOCK_EX);unset($file[0]);fputs($fp, implode("",$file));flock ($fp,LOCK_UN);fclose($fp);}if ($_SESSION['log']!="" && md5($_SESSION['par'])!="" && md5($_SESSION['par'])==$provpar && $_SESSION['log']==$provlog ) { $ufile = file(BASEDIR."local/profil/$log.prof"); $udata = explode(":||:",$ufile[0]);$udata[14]=$ip;$udata[9]++;$udata[36]++;$udata[41]++;for ($u=0; $u<$config_userprofkey; $u++){$utext.=$udata[$u].':||:';}if($udata[0]!="" && $udata[1]!="" && $udata[4]!="" && $utext!=""){$fp=fopen(BASEDIR."local/profil/$log.prof","a+");flock($fp,LOCK_EX); ftruncate($fp,0); fputs($fp,$utext);fflush($fp);flock($fp,LOCK_UN);fclose($fp); unset($utext);}}header ("Location: index1.php?addon&".SID);?>