现在所有按钮都可见,点击后按钮消失。我想按钮在一定时间内显示。在按钮上显示本周的一个按钮。不要同时显示所有按钮。任何帮助表示赞赏。
<script>
function enableButton(thisButton, nextButton) {
thisButton.style.display = "none";
document.getElementById(nextButton).disabled = false;
}
</script>
<center> MUST ONLY SHOW 1 BUTTON PER WEEK!!!!NOT ALL</center>
<br />
<center>
<input type="button" id="button1" value="September 1 - September 5"
onclick="enableButton(this, 'button2')" /><br>
<input type="button" id="button2" value="September 8 - September 13"
disabled onclick="enableButton(this, 'button3')" /><br>
<input type="button" id="button3" value="September 16 - September 20"
disabled onclick="enableButton(this, 'button4')" /><br>
<input type="button" id="button4" value="September 23 - September 27"
disabled onclick="enableButton(this, 'button5')" /><br>
</center>