async function playTrack(url, name) { try { // Resume context if browser suspended it if (audioCtx.state === 'suspended') { await audioCtx.resume(); } // Add a cache-buster to force a fresh "handshake" with Cloudflare const cacheBuster = "?cb=" + Date.now(); audio.src = url + cacheBuster; // Finalize the source load audio.load(); // Attempt playback await audio.play(); document.getElementById('status').innerText = `STREAMING: ${name.toUpperCase()}`; console.log("Stream Successful: " + url); } catch (e) { console.error("Initialization Error Details:", e); document.getElementById('status').innerText = "STREAM ERROR: CHECK CORS"; } }