- 1

Can anybody help with this module quiz of web development fundamentals

Your page has a text field with the id="num" and a button with id="print". Fill in the blanks to handle the click event on the button and alert the value of the text field. window .onload = function() { let n = document.getElementById("num"); let btn = document.getElementById(" print "); btn .onclick = function() { alert (n. ____ ); }; }; what will come in that blank space andd why

25th Jan 2023, 6:27 PM
Vikash
Vikash - avatar
1 Respuesta
+ 2
Asked to print button value.. So use : n.value or n.innerHTML;
25th Jan 2023, 6:51 PM
Jayakrishna 🇮🇳