Просмотр файла status/index.php

Размер файла: 1.08Kb
<?php
/*
require '../inc/func.php';
bk_head('Trạng Thái');
require '../inc/head.php';

if(!$user){
header('location: index.php');
}
echo '<div class="list1">';
if(isset($_POST['chat'])){

$content = bk_check($_POST['content']);
$cid = $userid;
$ctime = time();

if(empty($content)){
err ('Nội dung trống!');
}elseif(strlen($content) > 9999 || strlen($content) < 3)
{
err ('Lỗi! Nội dung từ 3-9999 ký tự');
}elseif(time() - 15 <= $users['ctime']) {
err ('Bạn vừa mới gửi một bài viết. Hãy chờ '.(15 - (time() - $users['ctime'])).' giây nữa nhé.!');
}else{
mysql_query("UPDATE users SET ctime = '".time()."' WHERE id = '$userid'");
mysql_query("INSERT INTO chat (cid, content, timline_id, time) VALUES ( '$userid', '$content', '$userid','$ctime')");
err ('&bull; Cập nhật trạng thái thành công!');
}
}

echo '<form action="" method="post"><textarea name="content"></textarea><br />
<input class="r2" type="submit" value="Đăng" name="chat"></form>';

echo '</div>';


bk_foot();
*/
header('location: /index.php');
?>