MULTIPLE CHOICE
- Using client-side scripting to handle light processing tasks such as data validation _____.
- minimizes transfer times across the Internet, making web applications faster
- confines processing to fewer hardware devices, limiting processing power
- increases server resource requirements and the related infrastructure costs
- is not possible, as you must use server-side scripting to validate forms
- Which element of the JavaScript expression document.write(“<p>The current time in “ + cityName + “ is “ + currentTime + “.</p>”); is a literal?
cityName
“<p>The current time in “
document
write
- Server-side scripting is used to _____.
- access or manipulate the user's web browser
- directly access a database on a system's back end
- handle the processing needed to display a user interface
- translate a request from a client into HTML
- Which of the following lines of code correctly uses an event handler attribute to display a dialog box when the webpage user clicks or taps a submit button?
<select type=”submit” onclick=”window.alert(Welcome!)” />
<input type=”submit” onclick=window.alert(“Welcome!”) />
<input type=”submit” onclick=”window.alert(‘Welcome!')” />
<input type=”submit” onblur=”window.alert(‘Welcome!')” />
- Which of the following languages is used for server-side scripting?
- HTML
- JavaScript
- Ruby
- Java
- When a variable is declared and initialized with the statement var velocity = 32;, this means that _____.
- it has a somewhat different scope than if it were declared using the let keyword
- it stores a constant value that cannot be changed
- the variable velocity can only hold a numerical value, not a text string
- the variable velocity was declared and initialized without using an assignment operator
- Which statement about the BOM is correct?
- JavaScript does not directly interact with the BOM.
- A formal set of standards for the BOM is maintained by the W3C.
- The BOM describes how to access a web page's contents.
- The BOM is largely the same among the various browsers currently available.
- JavaScript _____.
- was once supported by Internet Explorer only in a different form called JScript
- was developed by the European Computer Manufacturers Association
- has benefited from a single set of governing standards since it was introduced
- was not supported by major browsers for the first 11 years that it existed
- Which JavaScript statement assigns the value 3.49 to the price property of the
hotChocolate
object?hotChocolate.write(price, 3.49);
hotChocolate.price=3.49;
hotChocolate.price(3.49);
price.hotChocolate=3.49
- What code lines would you place before and after a set of JavaScript statements to embed them in an HTML file?
<script>
and</script>
script.execute; {
and}
<javascript>
and</javascript>
/*
and*/