ÿØÿà JFIFÿØÿà JFIF ÿØÿà JFIFÿØÿà JFIF   ÿþ$    File Manager

File Manager

Path: /home/u371470492/domains/theglitzcontest.com/public_html/

Melihat File: contestants.php

<?php 
session_start();
 ?>
 
 <?php include('config.php') ?>


<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.1/animate.min.css"/>
    <link rel="icon" href="img/LOGO TRANSPARENT.png">
    <link rel="stylesheet" href="splide/dist/css/splide.min.css">
    <link rel="stylesheet" href="font.css">
    <link rel="stylesheet" href="css/materialize.css">
    <link rel="stylesheet" href="js/jquery.js">
    <link rel="stylesheet" href="js/materialize.js">
    <link rel="stylesheet" href="icon/all.css">
            <!-- UIkit CSS -->
            <link rel="stylesheet" href="css/uikit.css">
        <link rel="stylesheet" href="css/uikit.min.css">
        <link rel="stylesheet" href="css/uikit-rtl.min.css">
        <link rel="stylesheet" href="css/uikit-rtl.css">
<!-- UIkit JS -->
<script src="js/uikit-icons.min.js"></script>
<script src="js/uikit.min.js"></script>
    <title>Contestants - Page </title>
</head>
<style>
    .link{
        color:#50585F;
        
        font-weight: bold;
        
    }
    .link:hover{
        color: #F8D868;
    }



    .body
    {
        background-color: #222227;
        
    }
    a
    {
        color: #F8D868;
    }

</style>
<body class="body">
<?php
include "topbar.php";
?>

<section style="margin-top: 6rem;">
            <h4 style="color:#886018; font-weight: bold; text-align: center;">All Contestants</h4>
<div class="center">
<a href="search.php" style="background-color: #886018" class="btn center"> <i class="material-icons left ">search</i>Find Contestant </a>
</div>
</section>

    <main class="container" > 
   










     
     <?php 
        $results_per_page = 12;
        $sql = "SELECT * FROM registration ORDER BY 'Childsname'";
     $cont=mysqli_query($conn,$sql);
            $number_of_results = mysqli_num_rows($cont);
            $number_of_pages = ceil($number_of_results/$results_per_page);
             if (!isset ($_GET['page']) ) {  
        $page = 1;  
        } else {  
        $page = $_GET['page'];  
            }; 

$page_first_result = ($page-1) * $results_per_page;
  $query = "SELECT * FROM registration ORDER BY Childsname ASC LIMIT " . $page_first_result . ',' . $results_per_page;  
    $result = mysqli_query($conn, $query);    
            $con=mysqli_fetch_all($result,MYSQLI_ASSOC);
         ?>


     <section>
      
        
            <div class="row"><br>
            <?php foreach($con as $cons){ ?>
                <div class="col l4 m6 s12 center" >
                    <div class="card z-depth-1 center hoverable" style="padding-bottom:     0px; border-radius: 2%;">
                       <br>
                            <img src="<?php echo $cons['Image']?>" class="avatar" style="border-radius: 5%; width: 60%; height:250px" alt="">
                        
                        <h6 class="center" style="margin-left:3px; margin-right:3px;  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #000000; font-weight: bold;"> <?php echo $cons['Childsname'] ?></h6>
                       
                        
                        
                         
                        <div style="font-weight: bold;color: #886018; font-size: 1.4rem ">                     
                       <?php echo $cons['Age']?>
                        </div>
                        <div class="card-action" style="background-color: #886018">
                        <form action="voter.php?id=<?php echo $cons['Id']?>" method="POST">
                            <input type="hidden" name="id" value="<?php echo $cas ?>">
                            <input type="submit" name="vote" class="btn z-depth-0" style="font-weight:bold; border-style:solid; border-width:2px; border-color:white; background-color: #886018" value="Vote">
                        </form>
                        </div>
                     <style>

                     </style>
                </div>
            </div>
            <?php } ?>
        </div>
    </section>

    <div class="center"><?php 
if($page == 1){
    $pages=$page+1;?>
    <a href="contestants.php?page=<?php echo $pages ?>" class="btn" style="background-color: #886018">Next Page</a> 
<?php }else{        
                    $pages=$page+1;
                    $pagen=$page-1; ?>
        <div class="center" style="text-align: center">
            <a href="contestants.php?page=<?php echo $pagen?>" class="btn" style="background-color: #886018">
                Previous Page
            </a>
            <?php if ($number_of_pages == $page) {?>
                <label style="font-size: 1.4rem">Last Page</label>
            <?php }else{ ?>
            <a href="contestants.php?page=<?php echo $pages?>" class="btn" style="background-color: #886018">
                Next Page
            </a>
        <?php } ?>
        </div>
<?php }?>
    </div>
    </main>

<br>

<?php
include "bottombar.php";
?>


    <script src="js/jquery.js"></script>
    <script src="js/custom.js"></script>
    <script>
        $(document).ready(function(){

        $('.materialboxed').materialbox();
        $('.parallax').parallax();
        $('.carousel').carousel();
        $('.scrollspy').scrollSpy();
        $('.sidenav').sidenav();
        
        });
    </script>
</body>
</html>
ÿØÿà JFIF    ÿþ$ ÿØÿà JFIF    ÿþ$ ÿÂ