View file shouts/delete.php

File size: 1.03Kb
<?
/*
=============================================
Движок: SHCMS Engine
=============================================
Название файла: Удаление выбранных сообщений в мини чате
=============================================
Official website: http://shcms.ru
=============================================
*/
define('SHCMS', true);
include_once'../system/inc/basic_settings.php';
$shcmsengine['title'] = 'Мини-Чат';
include_once'../template/head.php';
$user4 = mysql_fetch_array(mysql_query("SELECT * FROM users WHERE id=$user_id"));
if($user4['team'] == 6)
{if($_GET['id']){$id =$_GET['id'];}
$r = mysql_fetch_array(mysql_query("SELECT * FROM shouts WHERE id=$id"));
$dele_ok = mysql_query("DELETE FROM shouts WHERE id=".$r['id']."");
if($dele_ok == true)
{
echo '<div class="actshcms">Пост Успешно удален</div>';
header('Refresh: 1; url=javascript:history.back()');
include_once'../template/foot.php';
exit();}}
include_once'../template/foot.php';
?>