예제 #1
0
<?php

include_once '../model/notify_model.php';
$m = new NotifyModel();
$notyfy_type = $_GET['notify_type'];
$page_id = $_GET['page_id'];
$id_nf = $_GET['id_nf'];
$flag['flag'] = 3;
$m->notifyReed($id_nf);
if ($notyfy_type == 1) {
    $url = 'baidang.php?diary_id=' . $page_id . '&id_nf=' . $id_nf;
}
if ($notyfy_type == 2) {
    $user2 = $page_id;
    //include '../controler/check_friend';
    $url = 'page_user.php?user_id=' . $page_id . '&friend=' . $flag['flag'];
}
header('Location:' . $url);
예제 #2
0
include '../model/comment_model.php';
include '../model/notify_model.php';
include '../model/user_model.php';
include '../model/like_model.php';
include '../model/friend_model.php';
$f = new FriendModel();
$l = new LikeModel();
$t = new DIaryModel();
$c = new CommentModel();
$n = new NotifyModel();
$m = new NotifyModel();
$u = new userModel();
$diary_id = $_GET['diary_id'];
$diary = $t->getDiary($diary_id);
$id_notify = $_GET['id_nf'];
$m->notifyReed($id_notify);
include 'header.php';
$i = 0;
?>
  </div>
  </div>
    <div class="container">
  		<?php 
if ($diary == NULL) {
    echo '<div class="well">';
    echo 'bai dang khong hop le </div>';
} else {
    //dem so comment
    $user = $u->getUser($_SESSION['id']);
    $submit = 'submit' . $i;
    if (isset($_POST[$submit])) {