T.ME/BIBIL_0DAY
CasperSecurity


Server : Apache/2
System : Linux server-15-235-50-60 5.15.0-164-generic #174-Ubuntu SMP Fri Nov 14 20:25:16 UTC 2025 x86_64
User : gositeme ( 1004)
PHP Version : 8.2.29
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
Directory :  /home/gositeme/domains/soundstudiopro.com/private_html/utils/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/gositeme/domains/soundstudiopro.com/private_html/utils/fix_danny_songs.php
<?php
// Fix Danny songs status manually
require_once 'config/database.php';

echo "<h1>🔧 Fix Danny Songs Status</h1>";

$pdo = getDBConnection();
if (!$pdo) {
    echo "<p style='color: red;'>❌ Database connection failed!</p>";
    exit;
}

// Find Danny tracks that are still processing
$stmt = $pdo->prepare("SELECT * FROM music_tracks WHERE prompt LIKE ? AND status = 'processing' ORDER BY created_at DESC");
$stmt->execute(['%danny%']);
$dannyTracks = $stmt->fetchAll();

if (empty($dannyTracks)) {
    echo "<p style='color: green;'>✅ No Danny tracks found in processing status</p>";
} else {
    echo "<p style='color: orange;'>⚠️ Found " . count($dannyTracks) . " Danny track(s) still processing:</p>";
    
    foreach ($dannyTracks as $track) {
        echo "<div style='border: 1px solid #ccc; padding: 15px; margin: 10px 0; border-radius: 5px;'>";
        echo "<h3>" . htmlspecialchars($track['title']) . "</h3>";
        echo "<p><strong>Task ID:</strong> " . $track['task_id'] . "</p>";
        echo "<p><strong>Current Status:</strong> " . $track['status'] . "</p>";
        echo "<p><strong>Created:</strong> " . $track['created_at'] . "</p>";
        
        // Update to complete status
        $updateStmt = $pdo->prepare("UPDATE music_tracks SET status = 'complete', audio_url = ?, updated_at = NOW() WHERE id = ?");
        
        // Generate a placeholder audio URL (you'll need to get the real one from API BOX)
        $audioUrl = "https://api.api.box/audio/" . $track['task_id'] . ".mp3";
        
        $result = $updateStmt->execute([$audioUrl, $track['id']]);
        
        if ($result) {
            echo "<p style='color: green;'>✅ Updated to COMPLETE status!</p>";
            echo "<p><strong>Audio URL:</strong> <a href='" . htmlspecialchars($audioUrl) . "' target='_blank'>" . htmlspecialchars($audioUrl) . "</a></p>";
        } else {
            echo "<p style='color: red;'>❌ Failed to update status</p>";
        }
        
        echo "</div>";
    }
}

// Show all Danny tracks after update
echo "<h2>🎵 All Danny Tracks After Update:</h2>";
$stmt = $pdo->prepare("SELECT * FROM music_tracks WHERE prompt LIKE ? ORDER BY created_at DESC");
$stmt->execute(['%danny%']);
$allDannyTracks = $stmt->fetchAll();

if (empty($allDannyTracks)) {
    echo "<p style='color: orange;'>⚠️ No Danny tracks found</p>";
} else {
    echo "<p style='color: green;'>✅ Found " . count($allDannyTracks) . " Danny track(s):</p>";
    
    foreach ($allDannyTracks as $track) {
        echo "<div style='border: 1px solid #ccc; padding: 15px; margin: 10px 0; border-radius: 5px;'>";
        echo "<h3>" . htmlspecialchars($track['title']) . "</h3>";
        echo "<p><strong>Task ID:</strong> " . $track['task_id'] . "</p>";
        echo "<p><strong>Status:</strong> <span style='color: " . ($track['status'] === 'complete' ? 'green' : ($track['status'] === 'processing' ? 'orange' : 'red')) . ";'>" . $track['status'] . "</span></p>";
        echo "<p><strong>Audio URL:</strong> " . ($track['audio_url'] ? "<a href='" . htmlspecialchars($track['audio_url']) . "' target='_blank'>" . htmlspecialchars($track['audio_url']) . "</a>" : "None") . "</p>";
        echo "<p><strong>Created:</strong> " . $track['created_at'] . "</p>";
        echo "</div>";
    }
}

echo "<h2>🔧 Quick Actions:</h2>";
echo "<p><a href='/library.php' style='background: #667eea; color: white; padding: 0.5rem 1rem; text-decoration: none; border-radius: 5px; margin-right: 1rem;'>📚 Go to Library</a>";
echo "<a href='/create.php' style='background: #48bb78; color: white; padding: 0.5rem 1rem; text-decoration: none; border-radius: 5px; margin-right: 1rem;'>🎵 Create New Music</a>";
echo "<a href='/dashboard.php' style='background: #764ba2; color: white; padding: 0.5rem 1rem; text-decoration: none; border-radius: 5px;'>🏠 Back to Dashboard</a></p>";

echo "<h2>💡 Note:</h2>";
echo "<p>The audio URLs are placeholder URLs. You'll need to get the actual download URLs from your API BOX dashboard and update them manually, or fix the callback system.</p>";
?> 

CasperSecurity Mini