In "Magnus, Robot Fighter 4000 A.D.," Magnus battles on a monstrous planet against the evil Xyrkol and flame-throwing robots. Set in the distant future, the plot follows Magnus as he defends humanity from rogue machines. The vibrant cover artwork showcases a dynamic action scene. The comic is part of Gold Key's classic sci-fi series from the 1960s.
';
responseDiv.style.display = 'block';
submitButton.disabled = false;
});
};
// Make closePopup function global so it can be called from the popup HTML
window.closePopup = function(ctaId) {
const popup = document.getElementById(`popupOverlay_${ctaId}`);
if (popup) {
popup.remove();
}
};
// Global function to load spin wheel in popup
window.loadSpinWheelInPopup = function(wheelId, containerId) {
const container = document.getElementById(containerId);
if (!container) return;
// Include the spin wheel widget component
fetch(`/components/spin-wheel/spin-wheel-widget.php?wheel_id=${wheelId}&showTitle=false&showDescription=false`)
.then(response => response.text())
.then(html => {
container.innerHTML = html;
// Initialize the spin wheel JavaScript if available
if (typeof initSpinWheel === 'function') {
initSpinWheel(wheelId);
}
})
.catch(error => {
console.error('Error loading spin wheel:', error);
container.innerHTML = `
Unable to load spin wheel. Please refresh the page.
`;
});
};
}
// Call the function when the DOM is fully loaded
document.addEventListener('DOMContentLoaded', initPopupCTA);