OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
eSamudaay
/
process
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
10/10/2024 10:20:39 AM
rwxr-xr-x
📄
b.get.section.curated.php
17.96 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
b.get.section.newsletter.php
18.39 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
bchk.login.php
1.84 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
chk.logged.in.php
1.16 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
chk.login.php
1.84 KB
08/29/2024 12:17:53 PM
rw-r--r--
📁
eyecandy
-
08/29/2024 12:17:56 PM
rwxr-xr-x
📄
get.section.account.php
8.47 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.admin.php
16.74 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.analytics.php
11.45 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.collection.php
58.52 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.community.php
6.8 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.create.php
22.41 KB
08/29/2024 12:17:53 PM
rw-r--r--
📄
get.section.curated.php
36.3 KB
08/29/2024 12:47:09 PM
rw-r--r--
📄
get.section.dashboard.php
3.31 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.feed.php
7.42 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.genai.php
12.72 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.genaicreative.php
12.74 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.general.php
9.31 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.newsletter.php
18.42 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.request.article.php
5.82 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.settings.php
21.15 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.team.php
6.73 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
get.section.utils.php
4.1 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
logout.php
428 bytes
08/29/2024 12:17:54 PM
rw-r--r--
📄
sendgrid.php
3.62 KB
08/29/2024 12:17:54 PM
rw-r--r--
📄
upload.php
2.4 KB
08/29/2024 12:17:54 PM
rw-r--r--
Editing: b.get.section.curated.php
Close
<? // Cream: Cream Curated require_once '../inc/validate.logged.php'; require_once '../inc/config.php'; require_once '../inc/simplepie/autoloader.php'; include '../newReader/inc/db.php'; include '../newReader/inc/function.php'; ?> <ol class="breadcrumb my-3"> <li class="breadcrumb-item w-100" style="display:flex; justify-content:space-between;"> <div class="text-left "> <h4 class="mt-1" style="font-size: 1.25rem;">Curated For You</h4> </div> <div class="text-right "><button type="button" id="buttonAddCollection" class="hide btn btn-success" onclick="chkAddCollection()">Add selected to My Collection</button></div> </li> </ol> <div class="panelFeeds pr-2"> <? // foreach ($feed->get_items() as $item) { // $isExist = 0; // $feedTitle = $item->get_title(); // $enclosure = $item->get_enclosure(); // if ($enclosure) { // $feedImg = $enclosure->get_link(); // } else { // $feedImg = $_SERVER["DOCUMENT_ROOT"]."/eyecandy/stk.jpeg"; // } // $feedURL = $item->get_permalink(); // $feedPublisher = substr($feedURL, strpos($feedURL, ".") + 1); // $feedPublisher = ucfirst(strtok($feedPublisher, '.')); // $feedDesc = $item->get_description(); // $feedDate = $item->get_date('j F Y | g:i a'); $sql = 'SELECT title, url, description, image, date FROM rss_feeds_articles ORDER BY DATE desc LIMIT 200'; $result = $mysqli->query($sql); // Check if the query was successful if (!$result) { die('Query Error: ' . $mysqli->error); } while ($row = $result->fetch_assoc()) { $feedTitle = stripslashes($row['title']); $feedURL = stripslashes($row['url']); $feedImg = stripslashes($row['image']); $feedDesc = filter_desc($img, stripslashes($row['description'])); $randomNumber = rand(1, 13); if (!isValidImageUrl($feedImg)) { $feedImg = "http://knoblyreader.com/process/eyecandy/" . $randomNumber . ".jpeg"; //"https://th.bing.com/th/id/OIP.TPlSRAtpxf7Y2EQ4pkty_wHaFb?rs=1&pid=ImgDetMain"; } $feedDate = stripslashes($row['date']); $feedPublisher = substr($feedURL, strpos($feedURL, ".") + 1); $feedPublisher = ucfirst(strtok($feedPublisher, '.')); ?> <div class="card p-0 mb-3 border-0" style="background-color:#f5ede7"> <div class="panelFeed card-body p-2"> <div class="row no-gutters align-self-start"> <div class="col-auto"> <img src="<?= $feedImg ?>" alt="" class="img-fluid" style="max-width: 100px; height: auto;"> </div> <div class="col pl-1"> <h4 class="m-0 align-self-start" style="font-size: 1.25rem;"> <a id="<?= $feedTitle ?>" href="<?= $feedURL ?>" target="_blank" style="color:#f26522"> <?= $feedTitle ?> <br> <span style="position: absolute; top: -9999px; left: -9999px"><?= $feedURL ?></span> </a> </h4> </div> </div> <div class="row no-gutters mt-2"> <div class="col-12"> <p class="m-0" style="color:#7d7d7d; font-size: 1rem;"><?= $feedDesc ?></p> </div> </div> <div class="row no-gutters mt-2"> <div class="col-12 col-md-6 text-center text-md-left"><?= $feedPublisher ?> • <?= $feedDate ?></div> <div class="data col-12 col-md-6 text-center text-md-right mt-2 mt-md-0 d-flex justify-content-end align-items-center" data-feed-title="<?= $feedTitle ?>" data-feed-url="<?= $feedURL ?>" data-feed-publisher="<?= $feedPublisher ?>" data-feed-desc="<?= htmlentities($feedDesc) ?>"> <div class="mr-2"> <button class="btn btn-outline-secondary mic-button play-button" data-title="<?= urlencode($feedTitle ?? " ") ?>" data-description="<?= urlencode($feedDesc ?? " ") ?>"> <i class="fas fa-volume-up"></i> </button> <button class="btn btn-outline-secondary mic-button pause-button" style="display:none;"> <i class="fas fa-pause"></i> </button> <button class="btn btn-outline-secondary mic-button resume-button" style="display:none;"> <i class="fas fa-play"></i> </button> <button class="btn btn-outline-secondary mic-button stop-button" style="display:none;"> <i class="fas fa-stop"></i> </button> </div> <label class="btn btn-outline-secondary mic-button icon-container" style="margin-bottom: 0px;margin-right: 7px;"> <i class="far fa-bookmark" id="bookmarkIcon"></i> <input type="hidden" id="metadata" data-title="<?= $feedTitle ?>" data-url="<?= $feedURL ?>" description="<?= $feedDesc ?>"> </label> <button class="btn btn-outline-secondary mic-button" onclick="CopyToClipboards('<?= $feedURL ?>')"> <i class="fa-solid fa-arrow-up-from-bracket"></i> </button> </div> </div> </div> </div> <? } ?> </div> <script type="text/javascript"> $(function() { generateSM(); }); </script> <script> var isPlaying = false; $(document).ready(function() { // Play button click handler $('.play-button').on('click', function() { var title = decodeURIComponent($(this).data('title')); var desc = decodeURIComponent($(this).data('description')); playAudio(title, desc, $(this)); }); // Function to play audio function playAudio(title, desc, button) { var audio = new Audio(); if (isPlaying) { console.log("Audio is already playing. Cannot start another instance."); return; } console.log("Starting audio playback..."); isPlaying = true; // Set flag to true to indicate audio playback has started // Ajax call to get audio file URL $.ajax({ url: '../texttovoice/processvoice.php', type: 'POST', data: { title: title, description: desc }, success: function(response) { audio.src = response; audio.play(); // Update button visibility button.hide(); button.siblings('.pause-button').show(); button.siblings('.stop-button').show(); // Pause button click handler button.siblings('.pause-button').on('click', function() { audio.pause(); $(this).hide(); $(this).siblings('.resume-button').show(); }); // Resume button click handler button.siblings('.resume-button').on('click', function() { audio.play(); $(this).hide(); $(this).siblings('.pause-button').show(); }); button.siblings('.stop-button').on('click', function() { audio.pause(); // Pause the audio (assuming this stops playback) audio.currentTime = 0; // Reset audio playback to the beginning button.siblings('.resume-button').hide(); // Hide resume button if shown button.siblings('.stop-button').hide(); button.siblings('.pause-button').hide(); button.show(); isPlaying = false; }); // Reset when audio ends audio.onended = function() { isPlaying = false; button.show(); button.siblings('.pause-button').hide(); button.siblings('.resume-button').hide(); button.siblings('.stop-button').hide(); }; }, error: function(xhr, status, error) { console.error("Error playing audio:", error); } }); } }); function broadcast(link) { if (isPlaying) { console.log("Audio is already playing. Cannot start another instance."); return; } console.log("Starting audio playback..."); isPlaying = true; // Set flag to true to indicate audio playback has started var braudio = new Audio(); console.log(link); braudio.src = link; braudio.play(); $('.broadcast-pause').show(); $('.broadcast-stop').show(); $('.broadcast-pause').on('click', function() { braudio.pause(); $('.broadcast-pause').hide(); $('.broadcast-resume').show(); }); $('.broadcast-resume').on('click', function() { braudio.play(); $('.broadcast-resume').hide(); $('.broadcast-pause').show(); }); $('.broadcast-stop').on('click', function() { braudio.pause(); braudio.currentTime = 0; $('.broadcast-pause').hide(); $('.broadcast-resume').hide(); $('.broadcast-stop').hide(); isPlaying = false; }); braudio.onended = function() { isPlaying = false; $('.broadcast-pause').hide(); $('.broadcast-resume').hide(); $('.broadcast-stop').hide(); }; } </script> <script> $(document).ready(function() { // Use event delegation or direct binding if relevant $('.icon-container').each(function() { var userId = <?= $gUserId ?>; var $container = $(this); var url = $container.find('#metadata').data('url'); // Extract URL from hidden input var $icon = $container.find('#bookmarkIcon'); // Find the icon within the current container // Trigger the check collection function checkCollection(userId, url, $icon); }); $(document).on('click', '.icon-container', function() { var userId = <?= $gUserId ?>; var $icon = $(this).find('#bookmarkIcon'); var metadata = $(this).find('#metadata'); // Extract data from the hidden input var feedTitle = metadata.data('title'); var feedUrl = metadata.data('url'); var feedDesc = metadata.attr('description'); var feedImg = metadata.data('image'); var feedPublisher = metadata.data('publisher'); var feedDate = metadata.data('date'); // Determine the current state of the icon if ($icon.hasClass('far fa-bookmark')) { // If the icon is inactive (outline), make it active (filled) addToCollection(userId, feedTitle, feedUrl, feedDesc); $icon.removeClass('far fa-bookmark').addClass('fas fa-bookmark'); } else { // If the icon is active (filled), make it inactive (outline) removeFromCollection(userId, feedUrl); $icon.removeClass('fas fa-bookmark').addClass('far fa-bookmark'); } }); }); function checkCollection(userId, url, iconElement) { var $icon = $(iconElement); // Use the passed icon element $.ajax({ url: '../inc/hhandler.php', type: 'POST', contentType: 'application/json', data: JSON.stringify({ action: 'checkColl', file: 'curated', userId: userId, url: url }), success: function(response) { var result = JSON.parse(response); if (result.status === 'success') { if (result.count > 0) { $icon.removeClass('far fa-bookmark').addClass('fas fa-bookmark'); } } else { console.error('Failed to check collection: ' + result.message); } }, error: function(xhr, status, error) { console.error('AJAX request failed: ' + error); } }); } function addToCollection(userId, title, url, description) { $.ajax({ url: '../inc/hhandler.php', type: 'POST', contentType: 'application/json', data: JSON.stringify({ action: 'add', file: 'curated', userId: userId, title: title, url: url, description: description }), success: function(response) { var result = JSON.parse(response); if (result.status === 'success') { console.log('Added to collection: ' + result.message); } else { console.error('Failed to add to collection: ' + result.message); } }, error: function(xhr, status, error) { console.error('AJAX request failed: ' + error); } }); } function removeFromCollection(userId, url) { $.ajax({ url: '../inc/hhandler.php', type: 'POST', contentType: 'application/json', data: JSON.stringify({ action: 'remove', userId: userId, url: url }), success: function(response) { var result = JSON.parse(response); if (result.status === 'success') { console.log('Removed from collection: ' + result.message); } else { console.error('Failed to remove from collection: ' + result.message); } }, error: function(xhr, status, error) { console.error('AJAX request failed: ' + error); } }); } </script> <style> .mic-button { transition: transform 0.3s ease; /* Example transition */ } .mic-button:hover { transform: scale(1.1); /* Example transform on hover */ } </style>