���� JFIF �� � ( %"1"%)+...383,7(-.-
![]() Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/7.4.20 System : Linux st2.domain.com 3.10.0-1127.10.1.el7.x86_64 #1 SMP Wed Jun 3 14:28:03 UTC 2020 x86_64 User : apache ( 48) PHP Version : 7.4.20 Disable Function : NONE Directory : /var/www/html/netphim/code/guest/ |
<?php $type = $CORE->input['type'] ?? 'list'; $CORE->title_page = 'Comment of '.$ob_user->guest_fullname; $user_id = intval($ob_user->user_id); $where = " AND user_id_post='$user_id' AND parent_id=0 "; $order_by = 'time_post DESC,like_num DESC'; $pageNum = isset($_GET['pageNum']) ? intval($_GET['pageNum']) : 1; $pageSize = 25; $from = (($pageNum * $pageSize) - $pageSize); $t = $DB->fetch_row($DB->query("SELECT count(*) as total FROM tb_comment WHERE 1 ".$where)); $total = $t['total']; $smarty->assign('total',$total); $totalPage = ceil($total / $pageSize); $q_comment = $DB->query("SELECT * FROM tb_comment WHERE 1 ".$where." ORDER BY $order_by LIMIT $from,$pageSize"); $list = ''; $flag = ''; while($r_comment = $DB->fetch_row($q_comment)) { $comment_id = $r_comment['comment_id']; $date_comment = date('d/m/Y h:i:s A', $r_comment['time_post']); $date_comment2 = date('Y-m-d H:i:s', ($r_comment['time_post'] - (12 * 60 * 60))); $time_comment = $func->time_ago($r_comment['time_post']); $time_flag = 'Ngày '.date('d/m/Y',$r_comment['time_post']); if($flag!=$time_flag){ $list .= '<div class="time-label"> <span class="bg-danger"> <i class="fal fa-calendar"></i> '.$time_flag.' </span> </div>'; $flag=$time_flag; } if($r_comment['epi_slug']==''){ $r_comment['epi_slug']='Full'; } if($r_comment['epi']<0){ $r_comment['epi']=0; } $list .= '<div id="comment_'.$comment_id.'"> <i class="fal fa-comments"></i> <div class="timeline-item"> <span class="time"><i class="far fa-clock"></i> '.$time_comment.'</span> <h3 class="timeline-header"><a href="/'.$r_comment['phim_slug'].'/" class="manga">'.$r_comment['phim_name'].'</a> <a href="/'.$r_comment['phim_slug'].'/'.$r_comment['epi'].'-'.$r_comment['epi_slug'].'/" class="chapter">'.$r_comment['phim_name'].' Tập '.$r_comment['epi_slug'].'</a></h3> <div class="timeline-body"> '.html_entity_decode($r_comment['comment_content']).' </div> <div class="timeline-footer"> <a href="/'.$r_comment['phim_slug'].'/#tab_comment_id" class="btn btn-warning btn-flat btn-sm">Xem</a> <a href="javascript:void(0);" class="btn btn-danger btn-sm" onclick="deleteComment('.$comment_id.')">Xóa</a> </div> </div> </div>'; $q_sub = $DB->query("select * from (select * from tb_comment order by parent_id, comment_id) products_sorted, (select @pv := '".$comment_id."') initialisation where find_in_set(parent_id, @pv) and length(@pv := concat(@pv, ',', comment_id));"); $list_sub = ''; while($r_sub = $DB->fetch_row($q_sub)) { $comment_sub_id = $r_sub['comment_id']; $date_comment = date('d/m/Y h:i:s A', $r_sub['time_post']); $date_comment2 = date('Y-m-d H:i:s', $r_sub['time_post']); $time_comment = $func->time_ago($r_sub['time_post']); $list_sub .= '<div id="comment_'.$comment_sub_id.'"> <i class="far fa-comments-alt"></i> <div class="timeline-item"> <span class="time"><i class="far fa-clock"></i> '.$time_comment.'</span> <h3 class="timeline-header"><a href="/'.$r_sub['phim_slug'].'/">'.$r_sub['phim_name'].'</a> commented on '.$r_sub['user_id_post_name'].'</h3> <div class="timeline-body"> '.html_entity_decode($r_sub['comment_content']).' </div> <div class="timeline-footer"> <a href="/'.$r_sub['phim_slug'].'/#tab_comment_id" class="btn btn-warning btn-flat btn-sm">View comment</a> <a href="javascript:void(0);" class="btn btn-danger btn-sm" onclick="deleteComment('.$comment_sub_id.')">Delete</a> </div> </div> </div>'; } if(!empty($list_sub)){ $list .= $list_sub; } } $smarty->assign('list_comment',$list); $nav = $print->Pagination($totalPage,$pageNum,'pages','?act=guest&code=comment'); $smarty->assign('nav',$nav); $title_page = 'Bình luận của tài khoản '.$ob_user->guest_fullname; $smarty->assign('title_page',$title_page); $smarty->assign('des_page',str_replace('"',"'",strip_tags($arr_option['blogdescription']))); $smarty->assign('image_page',$INFO['home_url'].$arr_option['share_image_website']); $left_menu=left_menu(); $smarty->assign('left_menu',$left_menu); ?>