����JFIF��H�H����Exif��MM�*���� ��3����V�����3������3�(��������������������3�����
Server IP : 162.0.232.25 / Your IP : 3.145.10.9 Web Server : LiteSpeed System : Linux premium276.web-hosting.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64 User : kwacuqig ( 988) PHP Version : 8.2.26 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/kwacuqig/malawisounds.com/ |
Upload File : |
<?php include 'connect.php'; include 'views.php'; function update() { global $views, $conn, $id; $seen = $views + 1; $up = "UPDATE `tbl_uploads` SET `views`='$seen' WHERE `id`='$id'"; if (!$query = mysqli_query($conn, $up)) { die(mysqli_error($conn)); } } if (isset($_GET['id']) && isset($_GET['time'])) { $id = mysqli_real_escape_string($conn, htmlentities(preg_replace('#[^0-9]#', '', $_GET['id']))); $date = mysqli_real_escape_string($conn, htmlentities(preg_replace('#[^0-9]#', '', $_GET['time']))); $current = time(); $added = $date - $current; $hours = floor($added / 3600); //converting seconds to hours then finding LCM $minutes = floor(((($added / 3600) - floor($added / 3600)) / 1) * 60); //extracting decimal,dividing by 1, multiplying by 60 finally taking LCM $seconds = floor(((($added / 60) - floor($added / 60)) / 1) * 60); //extracting decimal,dividing by 1 and multiplying by 60 if (!empty($id) && !empty($date)) { //checking if added time is greater than current time if ($date >= $current) { //checking if hours exceeds 6 hours if ($hours <= 3) { $sql = "SELECT `file`,`size`,`artist`,`title`,`image`,`genre`,`downloads`,`id`,`type`,`time`,`views`,`listened`,UNIX_TIMESTAMP() - `time` AS TimeSpent FROM `tbl_uploads` WHERE `id`='$id'"; if ($query_run = mysqli_query($conn, $sql)) { list($path, $size, $artist, $title, $image, $genre, $downloads, $id, $type, $time, $views, $listened, $timespent) = mysqli_fetch_array($query_run); $titleurl = str_replace(' ', '-', $title); $artisturl = str_replace(' ', '-', $artist); if (!ip_exists($user_ip)) { update(); ip_add($user_ip); } else { $sqli = "SELECT `id` FROM `hits_ip` WHERE `ip`='$user_ip'"; if (!$run = mysqli_query($conn, $sqli)) { die(mysqli_error($conn)); } list($sid) = mysqli_fetch_array($run); $sqli1 = "UPDATE `hits_ip` SET `ip`='$user_ip' WHERE `id`='$sid'"; if (!$run2 = mysqli_query($conn, $sqli1)) { die(mysqli_error($conn)); } update(); } } else { die(mysqli_error($conn)); } } else { die(" <html> <head> <title>LINK EXPIRED</title> <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\"> <meta charset=\"UTF-8\"> <link rel=\"shortcut icon\" href=\"Icons/malawisounds.ico\"> </head> <body style=\"background-image:url(./Icons/404.jpg);width:100%;height:100%;background-size:cover;background-position:center center;;background-repeatno-repeat\"> <h3 style=\"font-size:25px;font-family:arial;color:red;min-height;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);\"><center>OOPS! <br>LINK HAS EXPIRED</center></h3> </body> </html> "); } } else { die(" <html> <head> <title>LINK EXPIRED</title> <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\"> <meta charset=\"UTF-8\"> <link rel=\"shortcut icon\" href=\"Icons/malawisounds.ico\"> </head> <body style=\"background-image:url(./Icons/404.jpg);width:100%;height:100%;background-size:cover;background-position:center center;;background-repeatno-repeat\"> <h3 style=\"font-size:25px;font-family:arial;color:red;min-height;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);\"><center>OOPS! <br>LINK HAS EXPIRED</center></h3> </body> </html> "); } } else { die("<h3><center>SOME FIELD IS EMPTY</center></h3>"); } } else { die(mysqli_error($conn)); } ?> <!DOCTYPE html> <html lang="en"> <head> <link rel="icon" type="x-icon" href="Icons/malawisounds.ico"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width,initial-scale=1.0"> <title><?php echo "$title by $artist" ?></title> <!--open graph codes--> <meta property="og:url" content="https://malawisounds.com/songs.php?id=<?php echo $id; ?>" /> <meta property="og:type" content="music" /> <meta property="og:title" content="<?php echo "Download $title-by-$artist"; ?>" /> <meta property="og:image" content="https://malawisounds.com/images/<?php echo $image; ?>" /> <meta property="og:description" content="Download and Stream" /> <meta property="fb:app_id" content="197362031139140" /> <!--CSS Files--> <link rel="stylesheet" type="text/css" href="./css/animate.css"> <link rel="stylesheet" type="text/css" href="./css/load.css"> <link rel="stylesheet" type="text/css" href="./css/w3.css"> <link rel="stylesheet" type="text/css" href="bootstrap/css/bootstrap.min.css"> <link rel="icon" type="x-icon" href="Icons/malawisounds.ico"> <link rel="stylesheet" type="text/css" href="impact/stylesheet.css" /> <!--JS Files--> <script type="text/javascript" src="js/ajax.js"></script> <script type='text/javascript' src='//platform-api.sharethis.com/js/sharethis.js#property=5b67c4f0f3815e0011ed2735&product=inline-share-buttons' async='async'></script> <style type="text/css"> @media screen and (max-width:1000px) { body { background-image: none; } } </style> </head> <body> <div class="margin w3-animate-bottom"> <?php include './header.php'; ?> <!--Search bar--> <input type="text" id="search" placeholder=" SEARCH-MUSIC, ARTISTS" onkeyup="findmatch(this.value)" class="glyphicon glyphicon-search"> <!--search results goes here--> <div id="results" class="w3-container w3-light-grey"></div> <?php /////////////////////////////////////////////////////////ARTISTS///////////////////////////////////////////// //query for selecting artists $sql1 = "SELECT * FROM `biography` WHERE `trending`=1 ORDER BY `id` DESC"; if ($query_run = mysqli_query($conn, $sql1)) { echo "<div style=\"overflow-x:auto;background-color:#b7b7b7;padding:6px;margin:5px 0px;\">"; echo "<center class=\"w3-display-container\">"; echo "<table>"; echo "<tr>"; while ($row = mysqli_fetch_array($query_run)) { $path = $row['path']; $name = $row['artist_name']; ?> <td> <a href="artist=<?php echo str_replace(' ', '-', $name); ?>" target="_parent"> <img src="bio/<?php echo $path; ?>" alt="artist" /> </a> </td> <?php } echo "</tr>"; echo "</table>"; echo "</center>"; echo "</div>"; } else { die(mysqli_error($conn)); } ////////////////////////////////////////////////////////SONG////////////////////////////////////////////////////// ?> <!-- displaying time --> <div class="expires"> <table> <tr> <td>hr</td> <td>min</td> <td>sec</td> </tr> <tr> <td><?php echo $hours; ?></td> <td><?php echo $minutes; ?></td> <td><?php echo $seconds; ?></td> </tr> </table> </div> <div class="song"> <!--Artwork--> <center><img src="images/<?php echo $image; ?>" id="img-<?php echo $id; ?>" onclick="zoom('<?php echo $id; ?>')" alt="<?php echo $title; ?>"></center> <!--Onclick Image--> <div id="modal-<?php echo $id; ?>" class="modal" onclick="this.style.display='none'"> <span class="close" id="close-<?php echo $id; ?>">×</span> <img class="modal-content" id="img-modal-<?php echo $id; ?>" /> <div class="caption" id="caption-<?php echo $id; ?>"></div> </div> <!--Artist Name--> <h3> <div class="glyphicon glyphicon-user"></div> <?php echo strtoupper($artist); ?> </h3> <!--Song Details--> <div class="container-fluid"> <div class="row"> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-music"></div> <span class="trim"><?php echo $title; ?></span> </div> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-floppy-disk"></div> <?php echo $size . ' mb'; ?> </div> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-download-alt"></div> <?php echo $downloads; ?> </div> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-headphones"></div> <?php echo $listened; ?> </div> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-th"></div> <?php echo $genre; ?> </div> <div class="col-sm-4 col-xs-6"> <div class="glyphicon glyphicon-time"></div> <?php $days = floor($timespent / (60 * 60 * 24)); $months = floor($timespent / (60 * 60 * 24 * 30)); $years = floor($timespent / (60 * 60 * 24 * 365)); $remainder = $timespent % (60 * 60 * 24); $hours = floor($remainder / (60 * 60)); $remainder = $remainder % (60 * 60); $minutes = floor($remainder / 60); $seconds = $remainder % 60; if ($days == 1) { echo $days . ' day ago'; } else if ($days > 1 && $days <= 30) { echo $days . ' days ago'; } else if ($days > 730) { echo $years . ' years ago'; } else if ($days > 365 && $days <= 730) { echo $years . ' year ago'; } else if ($days > 60 && $days <= 365) { echo $months . ' months ago'; } else if ($days > 30) { echo $months . ' month ago'; } else if ($days > 1) { echo $days . ' days ago'; } else if ($days == 0 && $hours == 0 && $minutes == 0) { echo 'just now'; } else if ($days == 0 && $hours == 0 && $minutes == 1) { echo $minutes . ' minute ago'; } else if ($days == 0 && $hours == 0) { echo $minutes . ' minutes ago'; } else if ($days == 0 && $hours == 1) { echo $hours . ' hour ago'; } else if ($days == 0 && $hours > 1) { echo $hours . ' hours ago'; } ?> </div> </div> </div> <div class="w3-center"> <a class="download" href="download.php?id=<?php echo $id; ?>&name=<?php echo "$artist-$title"; ?>"> <div class="glyphicon glyphicon-download-alt"></div> Download </a> <a class="download" href="sid-<?php echo "$id-" . strtolower(str_replace(' ', '-', $title)) . '-by-' . strtolower(str_replace(' ', '-', $artist)); ?>" target="_parent"> <div class="glyphicon glyphicon-headphones"></div> Stream </a> </div> </div> <div class="sharethis-inline-share-buttons"></div> <?php /////////////////////////////////////////////////////////////ADVERT///////////////////////////////////////////// //query for selecting adverts from db $sql3 = "SELECT aid,ads_name FROM `ads` ORDER BY `aid` DESC"; if ($query_run = mysqli_query($conn, $sql3)) { list($id, $imagepath) = mysqli_fetch_array($query_run); echo "<div style=\"overflow-x:auto;background-color:#b7b7b7;\" class=\"merchandise\">"; echo "<table>"; echo "<tr>"; ?> <td> <center><img src="ads/<?php echo $imagepath; ?>" alt="advert" /></center> </td> <?php echo "</tr>"; echo "</table>"; echo "</div>"; } else { die(mysqli_error($conn)); } ?> <!--Footer--> <?php include './footer.php'; ?> </div> </body> </html> <script type="text/javascript" src="js/jquery.js"></script> <script type="text/javascript" src="js/nav.js"></script> <script src="./js/wow.js"></script> <script type="text/javascript"> function _(selector) { return document.querySelector(selector); } function zoom(id) { var qSelector = "#img-modal-" + id; document.querySelector(qSelector).style.display = 'block'; //original image var myImg = "img-" + id; //modal container var myModal = "modal-" + id; //image modal var img_modal = "img-modal-" + id; //caption var caption = "caption-" + id; //close var close = "close-" + id; //Get the modal var modal = document.getElementById(myModal); //Get the image and insert it inside the modal - use its "alt" text as a caption var img = document.getElementById(myImg); var modalImg = document.getElementById(img_modal); var captionText = document.getElementById(caption); modal.style.display = "block"; modalImg.src = img.src; captionText.innerHTML = img.alt; // Get the <span> element that closes the modal var span = document.getElementById(close); // When the user clicks on <span> (x), close the modal span.onclick = function() { modal.style.display = "none"; } } //trimming song title songTitle = _("span.trim").innerText; trimSongTitle = songTitle.slice(0, 14); if (_("span.trim").innerText.length > 14) { _("span.trim").innerHTML = trimSongTitle + '...'; } </script>