I am currently attempting to deactivate buttons that have been generated in JavaScript...
var upButton = document.createElement('button');
var downButton= document.createElement('button');
var deleteButton = document.createElement('button');
At this point, I am trying to select all the buttons but it is not functioning as expected...
function play() {
var buttons = document.getElementsByTagName("button");
buttons.disabled = true;
buttons.style.backgroundColor = "#DADAD9";
}
The function is being executed and operates, however, the deactivation part is not. Can anyone provide assistance? Thank you!