// Set the cookie if not already set
if (!document.cookie.includes('download-button')) {
document.cookie = "download-button=true; path=/; max-age=3600;";
}
// Check for the cookie and show the button
if (document.cookie.includes('download-button')) {
document.getElementById('download-button').style.display = 'block';
}
Set the cookie (optional if handled in JS)
setcookie('download-button', 'true', time() + 3600,
0 Comments