Task at hand:
Hide the 'level' input when the 'object' value is 0.
Current situation:
input type="text" id="level"
input type="text" id="object"
My attempt:
var lvl = document.getElementById("level")
var ogg = document.getElementById("object")
if (ogg == 0) {
lvl.style.display = 'none';
};
I am struggling to get this code to work as I am new to JavaScript. Any assistance would be greatly appreciated, thank you!