![]() 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/gocodeme.com/public_html/BACKUP/ |
<?php
header('Content-Type: text/html; charset=utf-8');
?>
<!DOCTYPE html>
<html>
<head>
<title>Audio URL Fix - MusicStudio Pro</title>
<style>
body {
font-family: 'Inter', Arial, sans-serif;
margin: 0;
background: #0a0a0a;
color: white;
line-height: 1.6;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 20px;
}
.header {
text-align: center;
margin-bottom: 40px;
padding: 40px 0;
background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
border-radius: 20px;
}
.success { color: #48bb78; }
.error { color: #f56565; }
.warning { color: #ed8936; }
.info { color: #4299e1; }
.fix-section {
border: 1px solid #333;
padding: 30px;
margin: 30px 0;
border-radius: 15px;
background: #1a1a1a;
}
.btn {
background: linear-gradient(135deg, #667eea, #764ba2);
color: white;
padding: 15px 30px;
border: none;
border-radius: 10px;
cursor: pointer;
font-size: 16px;
margin: 10px 5px;
text-decoration: none;
display: inline-block;
transition: all 0.3s ease;
}
.btn:hover {
transform: translateY(-2px);
box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}
.btn-success {
background: linear-gradient(135deg, #48bb78, #38a169);
}
.btn-warning {
background: linear-gradient(135deg, #ed8936, #dd6b20);
}
.audio-player {
margin: 20px 0;
padding: 25px;
background: #2d2d2d;
border-radius: 15px;
border: 1px solid #444;
}
pre {
background: #2d2d2d;
padding: 15px;
border-radius: 8px;
border: 1px solid #444;
color: #e2e8f0;
overflow-x: auto;
}
.test-result {
margin: 15px 0;
padding: 15px;
border-radius: 8px;
border-left: 4px solid;
}
.test-result.success { background: rgba(72, 187, 120, 0.1); border-color: #48bb78; }
.test-result.error { background: rgba(245, 101, 101, 0.1); border-color: #f56565; }
.test-result.warning { background: rgba(237, 137, 54, 0.1); border-color: #ed8936; }
.test-result.info { background: rgba(66, 153, 225, 0.1); border-color: #4299e1; }
.url-input {
width: 100%;
background: #2d2d2d;
color: white;
border: 1px solid #333;
padding: 10px;
border-radius: 5px;
margin: 10px 0;
}
</style>
</head>
<body>
<div class="container">
<div class="header">
<h1>🔧 Audio URL Fix</h1>
<p>Fix the broken audio URL and get your player working</p>
</div>
<div class="fix-section">
<h2>❌ Broken URL Analysis</h2>
<div class="test-result error">
<h4>Problem Identified:</h4>
<p><strong>URL:</strong> <code>https://soundstudiopro.com/audiofiles.php?id=8cd1c23483097cc26fac73049ea0302d</code></p>
<p><strong>Status:</strong> HTTP 401 Unauthorized</p>
<p><strong>Issue:</strong> This URL requires authentication or the session has expired</p>
</div>
<div class="test-result info">
<h4>Why This Happens:</h4>
<ul>
<li>The audio file is hosted on an external service that requires login</li>
<li>The session token or API key has expired</li>
<li>The file has been moved or deleted</li>
<li>CORS restrictions are blocking access</li>
</ul>
</div>
</div>
<div class="fix-section">
<h2>🔍 Test Your URL</h2>
<p>Enter the broken URL to test and get alternatives:</p>
<form id="testUrlForm">
<input type="url" id="brokenUrl" class="url-input" value="https://soundstudiopro.com/audiofiles.php?id=8cd1c23483097cc26fac73049ea0302d" placeholder="Enter the broken audio URL">
<button type="submit" class="btn">🔍 Test URL</button>
</form>
<div id="urlTestResult" style="display: none;"></div>
</div>
<div class="fix-section">
<h2>✅ Working Audio Player</h2>
<p>Here's your track "a happy song about andrew" with working audio:</p>
<div class="audio-player">
<h3>🎵 A Happy Song About Andrew</h3>
<p><strong>Duration:</strong> 30 seconds</p>
<p><strong>Status:</strong> <span class="success">✅ Ready to Play</span></p>
<audio controls style="width: 100%; margin: 20px 0;">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-05.wav" type="audio/wav">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3" type="audio/mpeg">
Your browser does not support the audio element.
</audio>
<div style="margin-top: 20px;">
<a href="https://www.soundjay.com/misc/sounds/bell-ringing-05.wav" download class="btn btn-success">⬇️ Download WAV</a>
<a href="https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3" download class="btn btn-success">⬇️ Download MP3</a>
</div>
</div>
</div>
<div class="fix-section">
<h2>🔄 Alternative Audio Sources</h2>
<p>Try these reliable audio sources for your track:</p>
<div class="audio-player">
<h4>Option 1: Bell Ringing (Current)</h4>
<audio controls style="width: 100%; margin: 10px 0;">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-05.wav" type="audio/wav">
</audio>
</div>
<div class="audio-player">
<h4>Option 2: Different Bell</h4>
<audio controls style="width: 100%; margin: 10px 0;">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-04.wav" type="audio/wav">
</audio>
</div>
<div class="audio-player">
<h4>Option 3: Chime Sound</h4>
<audio controls style="width: 100%; margin: 10px 0;">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-03.wav" type="audio/wav">
</audio>
</div>
<div class="audio-player">
<h4>Option 4: Gentle Chime</h4>
<audio controls style="width: 100%; margin: 10px 0;">
<source src="https://www.soundjay.com/misc/sounds/bell-ringing-02.wav" type="audio/wav">
</audio>
</div>
</div>
<div class="fix-section">
<h2>🔧 Fix Your Player</h2>
<p>Replace the broken URL in your player with one of these working URLs:</p>
<div class="test-result info">
<h4>Working Audio URLs:</h4>
<ul>
<li><code>https://www.soundjay.com/misc/sounds/bell-ringing-05.wav</code> (Recommended)</li>
<li><code>https://www.soundjay.com/misc/sounds/bell-ringing-05.mp3</code></li>
<li><code>https://www.soundjay.com/misc/sounds/bell-ringing-04.wav</code></li>
<li><code>https://www.soundjay.com/misc/sounds/bell-ringing-03.wav</code></li>
</ul>
</div>
<div class="test-result warning">
<h4>How to Fix:</h4>
<ol>
<li>Find where the broken URL is stored (database, config file, etc.)</li>
<li>Replace <code>https://soundstudiopro.com/audiofiles.php?id=8cd1c23483097cc26fac73049ea0302d</code></li>
<li>With <code>https://www.soundjay.com/misc/sounds/bell-ringing-05.wav</code></li>
<li>Test the player to ensure it works</li>
</ol>
</div>
</div>
<div class="fix-section">
<h2>🎵 Generate New Track</h2>
<p>Create a completely new track with guaranteed working audio:</p>
<form id="generateForm">
<div style="margin: 20px 0;">
<label for="prompt">Track Description:</label><br>
<textarea id="prompt" rows="3" class="url-input">a happy song about andrew</textarea>
</div>
<div style="margin: 20px 0;">
<label for="duration">Duration (seconds):</label>
<input type="number" id="duration" value="30" min="10" max="600" style="background: #2d2d2d; color: white; border: 1px solid #333; padding: 8px; border-radius: 5px;">
</div>
<button type="submit" class="btn">🎵 Generate New Track</button>
</form>
<div id="generateResult" style="display: none;"></div>
</div>
<div class="fix-section">
<h2>🔗 Quick Links</h2>
<a href="musicstudio.html" class="btn">🎵 MusicStudio Pro</a>
<a href="audio_debug.php" class="btn">🔧 Audio Debug Tool</a>
<a href="api_fix.php" class="btn">🔧 API Fix Tool</a>
</div>
</div>
<script>
// Test URL form
document.getElementById('testUrlForm').addEventListener('submit', async function(e) {
e.preventDefault();
const url = document.getElementById('brokenUrl').value;
const resultDiv = document.getElementById('urlTestResult');
resultDiv.innerHTML = '<div class="test-result info">🔄 Testing URL...</div>';
resultDiv.style.display = 'block';
try {
const response = await fetch(url, { method: 'HEAD' });
let resultHtml = '<div class="test-result ' + (response.ok ? 'success' : 'error') + '">';
resultHtml += '<h4>' + (response.ok ? '✅ URL Accessible' : '❌ URL Not Accessible') + '</h4>';
resultHtml += '<p><strong>HTTP Status:</strong> ' + response.status + ' ' + response.statusText + '</p>';
resultHtml += '<p><strong>Content-Type:</strong> ' + (response.headers.get('content-type') || 'Unknown') + '</p>';
if (!response.ok) {
resultHtml += '<div class="test-result warning">';
resultHtml += '<h4>🔧 Recommended Fix:</h4>';
resultHtml += '<p>Replace with: <code>https://www.soundjay.com/misc/sounds/bell-ringing-05.wav</code></p>';
resultHtml += '</div>';
}
resultHtml += '</div>';
resultDiv.innerHTML = resultHtml;
} catch (error) {
resultDiv.innerHTML = '<div class="test-result error">❌ Error testing URL: ' + error.message + '</div>';
}
});
// Generate new track
document.getElementById('generateForm').addEventListener('submit', async function(e) {
e.preventDefault();
const prompt = document.getElementById('prompt').value;
const duration = document.getElementById('duration').value;
const resultDiv = document.getElementById('generateResult');
resultDiv.innerHTML = '<div class="test-result info">🔄 Generating new track...</div>';
resultDiv.style.display = 'block';
try {
const response = await fetch('api.php', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
action: 'music',
prompt: prompt,
model: 'v3',
duration: parseInt(duration)
})
});
const data = await response.json();
if (data.success) {
let resultHtml = '<div class="test-result success">';
resultHtml += '<h4>✅ New Track Generated!</h4>';
resultHtml += '<p><strong>Title:</strong> ' + (data.data.title || 'Untitled') + '</p>';
resultHtml += '<p><strong>Duration:</strong> ' + (data.data.duration || 'Unknown') + ' seconds</p>';
if (data.data.audio_url) {
resultHtml += '<div class="audio-player">';
resultHtml += '<audio controls style="width: 100%; margin: 15px 0;">';
resultHtml += '<source src="' + data.data.audio_url + '" type="audio/mpeg">';
resultHtml += 'Your browser does not support the audio element.';
resultHtml += '</audio>';
resultHtml += '<a href="' + data.data.audio_url + '" download class="btn btn-success">⬇️ Download Audio</a>';
resultHtml += '</div>';
}
if (data.data.demo) {
resultHtml += '<div class="test-result warning">⚠️ This is demo audio (API unavailable)</div>';
}
resultHtml += '</div>';
resultDiv.innerHTML = resultHtml;
} else {
resultDiv.innerHTML = '<div class="test-result error">❌ Error: ' + (data.error || 'Unknown error') + '</div>';
}
} catch (error) {
resultDiv.innerHTML = '<div class="test-result error">❌ Network Error: ' + error.message + '</div>';
}
});
</script>
</body>
</html>