2018-01-28 16:40:49 +00:00
|
|
|
|
<?
|
|
|
|
|
if ($_SESSION['uid'] == null) header("Location: index.php");
|
|
|
|
|
$user = mysql_fetch_array(mysql_query("SELECT * FROM `users` WHERE `id` = '{$_SESSION['uid']}' LIMIT 1;"));
|
|
|
|
|
if ($user['battle']==0) {
|
|
|
|
|
echo'Нельзя использовать вне боя';
|
|
|
|
|
}
|
|
|
|
|
$_POST['target']=htmlspecialchars($_POST['target'], NULL, "");
|
|
|
|
|
if(preg_match("/__/",$_POST['target']) || preg_match("/--/",$_POST['target']))
|
|
|
|
|
{
|
|
|
|
|
echo"В тексте не должно присутствовать подряд более 1 символа '_' или '-'.";
|
|
|
|
|
}else{
|
|
|
|
|
$mess = $_POST['target'];
|
|
|
|
|
if ($user['sex'] == 1) {$action="выкрикнул";} else {$action="выкрикнула";}
|
2020-08-27 12:17:02 +00:00
|
|
|
|
addlog($user['battle'],'<span class=sysdate>'.date("H:i").'</span> '.Nick::id($user['id'])->short().' '.$action.': '.$mess.'<BR>');
|
2018-01-28 16:40:49 +00:00
|
|
|
|
}
|