<?php
include('session.php');

?>
<html lang="en">

<head>
    <title><?php echo $s0['instansi']; ?>: User Area</title>

    <!-- Meta -->
    <meta charset="utf-8">
    <!-- <meta content="width=device-width, initial-scale=1.0" name="viewport"> -->
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, height=device-height, initial-scale=0.65, maximum-scale=1, minimum-scale=0.65">
    <meta name="theme-color" content="#272b30">

    <!-- Favicon -->
    <link rel="icon" type="image/png" href="<?php echo $urlwebs; ?>/upload/favicon.png">

    <!-- CSS Global Compulsory -->

    <link rel="stylesheet" href="<?php echo $urlwebs; ?>/assets/home/bootstrap.web.min.css">
    <link href="https://fonts.googleapis.com/css?family=Abel" rel="stylesheet">
    <style>
        .blink_me {
            animation: blinker 1s step-start infinite;
        }

        @keyframes blinker {
            20% {
                opacity: 0.2;
            }
        }
    </style>
    <!-- JS Global Compulsory -->
    <script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@3.4.1/dist/js/bootstrap.min.js" integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd" crossorigin="anonymous"></script>
    <script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
    <script src="<?php echo $urlwebs; ?>/js/4dv5.js"></script>
    <script>
        function secondtominute(d) {
            var m = Math.floor(d / (60));
            var s = d - (m * 60);
            if (s < 10) s = '0' + s;
            return m + ':' + s;
        }
    </script>

</head>
<?php include('uptop.php'); ?>


    

        <div class="clearfix"></div>
        <link rel="stylesheet" href="<?php echo $urlwebs; ?>/assets/home/m.css">
        <!-- MAIN TAB -->

        <?php include('navtab.php'); ?>


        <div class="tab-content">

    <div id="fishing_wrap" class="tab-pane fade in active" style="padding-bottom: 30px">

        <div id="games_window_hacksaw">
            <ul class="nav nav-pills grabgtab" style="padding-bottom:0px; font-size:16px; font-weight:normal;">
                <li class="active" id="tab_hacksaw" style="width:24.5%; margin-left:2px; margin-bottom: 2px; font-weight: normal">
                    <a data-toggle="tab" href="#fish_window_hacksaw" style="padding-left:5px">
                        <span>
                            <img src="<?php echo $urlwebs; ?>/images/Desain_tanpa_judul_-_2025-09-16T195251.438-removebg-preview.png" height="25" alt="" style="vertical-align:bottom">&nbsp;Hacksaw
                        </span>
                    </a>
                </li>
            </ul>

            <div style="height:10px; background-color:#FFF" class="grabgtabbottom"></div>

            <div class="tab-content">

                <div id="fish_window_hacksaw" class="text-center tab-pane fade in active">
                    <?php
                    $sql_hacksaw = mysqli_query($conn, "SELECT * FROM `tb_game` WHERE `provider_code` = 'HACKSAW' AND status = 1 ORDER BY game_name ASC") 
                        or die(mysqli_error($conn));

                    if(mysqli_num_rows($sql_hacksaw) == 0){
                        echo "<p>Tidak ada game Hacksaw tersedia</p>";
                    }

                    while($game = mysqli_fetch_array($sql_hacksaw)){
                        $playUrl = isset($_SESSION['user']) 
                            ? $urlweb.'/m/gameplay.php?provider='.$game['provider_code'].'&gamecode='.$game['game_code'] 
                            : $urlweb.'/login/';
                    ?>
                        <div style="height:145px; width:175px; display:inline-block; text-align:center; vertical-align:top; cursor:pointer; margin:5px;">
                            <a href="<?php echo $playUrl; ?>">
                                <img src="<?php echo $game['banner']; ?>" style="width:165px">
                                <div style="text-align:center; margin-top:5px;"><?php echo $game['game_name']; ?></div>
                            </a>
                        </div>
                    <?php } ?>
                </div>

            </div>

        </div>

    </div>

</div>

    <div class="well well-sm container-fluid text-center" style="margin:0px; padding:5px; border-radius:0px; padding-bottom: 55px">
        © 2018 - 2023 Copyright <?php echo $s0['instansi']; ?>. All Rights Reserved.
    </div>

<!--tampilan /m/ versi mobile bawah trakhir alias footer--><!--next halaman footer-->
<?php include('footer.php'); ?>






</html>
