336). What is the property to access the first child of a node?

[A]timestamp.Child1
[B]timestamp.Child(1)
[C]timestamp.Child(0)
[D] timestamp.firstChild

Show Answer

337). What are the properties supporting CSS styles for a document element?

[A]style and font
[B]style and className
[C]size and style
[D]className and font

Show Answer

338). Which of the following object belongs to the style property?

[A]Element
[B]Window
[C]Location
[D]Dynamic

Show Answer

339). What is the purpose of the event handlers in the JavaScript?

[A]Adds innerHTML page to the code
[B] Performs handling of exceptions and occurrences
[C]Allows JavaScript code to alter the behaviour of windows
[D]Change the server location

Show Answer

340). Which handler is triggered when the content of the document in the window is stable and ready for manipulation?

[A]onload
[B]manipulate
[C]create
[D]onkeypress

Show Answer

341). When a program contains extensive use of event handlers, which of the following is necessary?

[A]Modular functions
[B]Nested functions
[C]Split up programs
[D]Global variables

Show Answer

342). What is the JavaScript code snippet to find all container elements with class “reveal”?

[A]var elements = document.getElementsByClassName(“reveal”);
[B]var elements = document.getElementByClassName(“reveal”);
[C]var elements = document.getElementByName(“reveal”);
[D] var elements = document.getElementsClassName(“reveal”);

Show Answer

343). What is the JavaScript code snippet to update the content of the timestamp element when the user clicks on it?

[A] timestamp.onLoad = function() { this.innerHTML = new Date().toString(); }
[B]timestamp.onclick = function() { this.innerHTML = new Date().toString(); }
[C] timestamp.onload = function() { this.innerHTML = new Date().toString(); }
[D] timestamp.onclick = function() { innerHTML = new Date().toString(); }

Show Answer

344). Which of the following is not an object?

[A]Element
[B]Location
[C]Position
[D]Window

Show Answer

345). What is the JavaScript code snippet to change the class and let the stylesheet specify the details?

[A]timestamp.className = “highlight”;
[B]timestamp.className = “change”;
[C]timestamp.className = “specify”;
[D]timestamp.className = “move”;

Show Answer