D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
self
/
root
/
proc
/
self
/
root
/
proc
/
self
/
root
/
home
/
markniuj
/
bazmeasar.com
/
Filename :
next-majlis.php
back
Copy
<?php include 'config.php'; ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>countdown</title> <meta content="width=device-width, initial-scale=1.0" name="viewport"> <meta content="" name="keywords"> <meta content="" name="description"> <!-- Favicon --> <link href="img/favicon.ico" rel="icon"> <!-- Google Web Fonts --> <link rel="preconnect" href="https://fonts.googleapis.com"> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> <link href="https://fonts.googleapis.com/css2?family=Barlow:wght@600;700&family=Ubuntu:wght@400;500&display=swap" rel="stylesheet"> <!-- Icon Font Stylesheet --> <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.0/css/all.min.css" rel="stylesheet"> <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.0/css/all.min.css" rel="stylesheet"> <link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.4.1/font/bootstrap-icons.css" rel="stylesheet"> <link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.4.1/font/bootstrap-icons.css" rel="stylesheet"> <!-- Libraries Stylesheet --> <link href="lib/animate/animate.min.css" rel="stylesheet"> <link href="lib/owlcarousel/assets/owl.carousel.min.css" rel="stylesheet"> <link href="lib/tempusdominus/css/tempusdominus-bootstrap-4.min.css" rel="stylesheet" /> <!-- Customized Bootstrap Stylesheet --> <link href="css/bootstrap.min.css" rel="stylesheet"> <!-- Template Stylesheet --> <link href="css/style.css" rel="stylesheet"> <style> .embed-responsive iframe { width: 100%; /* Adjust the width as needed */ height: 100%; /* Adjust the height as needed */ } </style> <style> .countdown { font-size: 85px; color: #e74c3c; margin-top: 20px; text-align: center; font-weight: 900; border: #ee8f00 solid 0px; } .share-buttons { margin-top: 20px; } .share-button { display: inline-flex; margin-right: 10px; } <style> .gm-style .default-card { padding: 5px 14px 5px 14px; background-color: coral;} </style> </head> <body> <!-- Spinner Start --> <!-- Spinner End --> <!-- Topbar Start --> <?php include 'include/topbar.php';?> <!-- Topbar End --> <!-- Navbar Start --> <?php include 'include/menu.php';?> <!-- Navbar End --> <!-- Page Header Start --> <div class="container-fluid page-header mb-5 p-0" style="background-image: url(img/carousel-bg-2.jpg);"> <div class="container-fluid page-header-inner py-5"> <div class="container text-center"> <h1 class="display-3 text-white mb-3 animated slideInDown">Next Majlis</h1> <nav aria-label="breadcrumb"> <ol class="breadcrumb justify-content-center text-uppercase"> <li class="breadcrumb-item"><a href="#">Home</a></li> <li class="breadcrumb-item"><a href="#">Pages</a></li> <li class="breadcrumb-item text-white active" aria-current="page">Videos</li> </ol> </nav> </div> </div> </div> <!-- Page Header End --> <!-- search Start --> <!-- Booking Start --> <div class="col-lg-12 col-md-12"> <div class="container"> <div class="row gx-5"> <?php // Get event details from the database // Fetch event data $sql = "SELECT * FROM events ORDER BY STR_TO_DATE(CONCAT(event_date, ' ', event_time), '%Y-%m-%d %H:%i') DESC LIMIT 1"; $result = $conn->query($sql); if ($result->num_rows > 0) { $row = $result->fetch_assoc(); $event_name = $row['event_name']; $event_nameurdu = $row['event_nameurdu']; $event_date = $row['event_date']; $event_time = $row['event_time']; $location = $row['location']; $countdown = $row['countdown']; // Calculate the end time of the event $end_time = strtotime("$event_date $event_time"); $current_time = time(); $remaining_time = $end_time - $current_time; echo "<center><h2>$event_name</h2></center>"; echo "<center><p>$event_nameurdu</p></center>"; echo "<center><p>Event Date: $event_date</p></center>"; echo "<center><p>Event Time: $event_time</p></center>"; if ($remaining_time > 0) { echo "<p class='countdown' id='countdown'></p>"; echo "<iframe src='$location' width='auto' height='auto' style='border:1;' allowfullscreen='' loading='lazy' referrerpolicy='no-referrer-when-downgrade'></iframe>"; // JavaScript countdown timer echo "<script> var countdown = $remaining_time; var countdownDisplay = document.getElementById('countdown'); function updateCountdown() { var days = Math.floor(countdown / (24 * 60 * 60)); var hours = Math.floor((countdown % (24 * 60 * 60)) / (60 * 60)); var minutes = Math.floor((countdown % (60 * 60)) / 60); var seconds = countdown % 60; countdownDisplay.innerHTML = days + 'd ' + hours + 'h ' + minutes + 'm ' + seconds + 's'; countdown--; if (countdown < 0) { countdownDisplay.innerHTML = 'Event has ended.'; } } updateCountdown(); // Display initial countdown setInterval(updateCountdown, 1000); // Update countdown every second </script>"; } else { echo "<p>Event has ended.</p>"; } } else { echo "No events found."; } // Close the database connection $conn->close(); error_reporting(E_ALL); ini_set('display_errors', 1); ?> </div> </div> </div> <!----search end --> <!-- Footer Start --> </div> </div> <?php include 'include/footer.php';?> <!-- Footer End --> <!-- Back to Top --> <a href="#" class="btn btn-lg btn-primary btn-lg-square back-to-top"><i class="bi bi-arrow-up"></i></a> <!-- Add Bootstrap JS and jQuery --> <script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.5.4/dist/umd/popper.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"></script> <!-- JavaScript Libraries --> <script src="https://code.jquery.com/jquery-3.4.1.min.js"></script> <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0/dist/js/bootstrap.bundle.min.js"></script> <script src="lib/wow/wow.min.js"></script> <script src="lib/easing/easing.min.js"></script> <script src="lib/waypoints/waypoints.min.js"></script> <script src="lib/counterup/counterup.min.js"></script> <script src="lib/owlcarousel/owl.carousel.min.js"></script> <script src="lib/tempusdominus/js/moment.min.js"></script> <script src="lib/tempusdominus/js/moment-timezone.min.js"></script> <script src="lib/tempusdominus/js/tempusdominus-bootstrap-4.min.js"></script> <!-- Template Javascript --> <script src="js/main.js"></script> </body> </html>