1. Which of the following is/are true regarding AJAX?
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
<request-line>
<headers>
<blank line>
[<request-body>]
Which of the following is not passed in the request-line?
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
purpose?
<div id=”statusCode”></div>
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
XMLHttpRequest.readyState
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
function foo ()
return 5;
}
What will the following code do?
var myVar = foo;
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
Answers:
- It’s an engine developed by Microsoft to load web pages faster
- It’s merely a concept with many implementation methods (XMLHttpRequest, iFrames…)
- It’s a server side scripting language used to serve partial parts of a webpage
- It’s a good way to reduce network traffic, if used correctly
- None of the above
Answers:
- Internet Explorer 5
- Internet Explorer 6
- Internet Explorer 7
- Firefox 2.0
- Safari 3.0
Answers:
- It can only be used with async requests
- It will remove the onreadystatechange event handler
- It will send an abort message to the remote server
- It changes readyState to 4 (aborted)
- None of the above
Answers:
- If true, the request doesn’t return anything.
- If true, the javascript engine is blocked while making the request
- If true, the send method returns immediately
- If true, the request object is destroyed when ‘send’ is executed
- If true, callbacks are executed
Answers:
- window.setTimeout(checkState, 10);
- window.setTimeout(checkState, 10000);
- window.setTimeout(checkState(), 10);
- None of the above
Answers:
- true
- false
<request-line>
<headers>
<blank line>
[<request-body>]
Which of the following is not passed in the request-line?
Answers:
- Type of request
- Resource to access
- Version of HTTP
- Browser name
- None of the above
Answers:
- no
- yes, if each AJAX request modifies the server side context, which would render a page similar to the actual JS modified page, if reloaded.
Answers:
- var oReq = new XMLHttpRequest ();
- var oReq = new ActiveXObject (“MSXML2.XMLHTTP.3.0”);
- var oReq = new IEHttpRequest (“XML”);
- None of the above
Answers:
- yes
- no
Answers:
- responseData
- responseBody
- responseString
- responseText
- responseXML
Answers:
- yes
- no
Answers:
- yes
- no
Answers:
- Yes
- No
Answers:
- No
- Yes
purpose?
<div id=”statusCode”></div>
Answers:
- var myDiv = document.getElementById (“statusCode”); myDiv.innerHTML = req.statusCode;
- var myDiv = document.getElementById (“statusCode”); myDiv.innerHTML = req.status;
- var myDiv = document.getElementById (“statusCode”); myDiv.setStatus (req.statusCode);
- var myDiv = document.getElementById (“statusCode”); myDiv.status = req.status;
- None of the above
Answers:
- Apache
- Sun application server
- lighttpd
- Microsoft web server
- Any HTTP server will work
Answers:
- <!– –>
- /* */
- //
- #
- –[[ ]]
Answers:
- myReq.setContentType (“text/xml”);
- myReq.contentType = “text/xml”;
- myReq.overrideContentType (“xml”);
- myReq.contentType = “xml”;
- myReq.setRequestHeader (“Content-Type”, “text/xml”);
Answers:
- yes
- no
Answers:
- Partial page processing
- Unresponsiveness of web pages
- Server side communication initiation
- Server crashes (failover)
- None of the above
Answers:
- yes
- no
Answers:
- It can only be implemented with the XMLHttpRequest object
- It can be used to update parts of a webpage without reloading it
- It can be used to make requests to the server without blocking the user (async)
- It requires a special AJAX enabled web server
- It cannot be used under Internet Explorer
Answers:
- Yes
- No
Answers:
- HTTP GET request for retrieving data (which will not change for that URL)
- HTTP POST request for retrieving data (which will not change for that URL)
- HTTP GET should be used when the state is updated on the server
- HTTP POST should be used when the state is updated on the server
Answers:
- To submit data to the server
- To retrieve data from the server
- To load additional code from the server
- To download an image
- All of the above
Answers:
- yes
- no
Answers:
- yes
- no
Answers:
- yes
- no
Answers:
- new
- delete
- this
- typeof
- All of the above are Javascript operators
Answers:
- It only contains the data of the page elements that need to be changed
- It contains both the data of the whole page and the data that needs to be changed in separate blocks
- It contains the data of the whole page
- It may contain anything
- None of the above
Answers:
- Yes
- No
Answers:
- JavaScript
- AppleScript
- PHP
- Ruby
- Java
Answers:
- yes
- no
Answers:
- true
- false
Answers:
- _my_var
- 2myVar
- MY_VAR
- __MyVar2__
- All are valid
Answers:
- yes
- no
Answers:
- To prevent the page scripts from executing
- To shield a part of a page from being modified by JS (like aDiv.innerHTML = ‘something’ has no effect)
- To enclose text to be displayed if the browser doesn’t support JS
- NOSCRIPT tag doesn’t exist
- None of the above
XMLHttpRequest.readyState
Answers:
- 0, The request is not initialized
- 1, The request has been set up
- 2, The request has been sent
- 3, The request is in process
- 4, The request is complete
- All of the above.
Answers:
- Java
- NetscapeScript
- ECMAScript
- XMLScript
- WebScript
Answers:
- JavaScript
- PHP
- Java
- Ruby
- Any language supported by the server
Answers:
- Partial page update
- Offline browsing
- Server side scripting
- All of the above
Answers:
- The browser back button cannot be used in most cases
- It makes the server and client page representation synchronization more difficult
- It loads the server too much
- It’s not supported by older browsers
- It augments the used bandwidth significantly
Answers:
- myRequest.onreadystatechange = calc;
- myRequest.onload = calc;
- myRequest.execute = calc;
- myRequest.addCallback (calc, “loaded”);
- None of the above
Answers:
- yes
- no
Answers:
- var array = Array.new;
- var array = [];
- var array = new Array;
- var array = new Array ();
- None of the above
Answers:
- Yes
- No
Answers:
- Yes
- No
Answers:
- Ability to handle processes independently from other processes
- Processes are dependent upon other processes
- Processes are not fully dependent on other processes
- None of the above
Answers:
- <script href=”myScript.js”>
- <script name=”myScript.js”>
- <script src=”myScript.js”>
- <script root=”myScript.js”>
function foo ()
return 5;
}
What will the following code do?
var myVar = foo;
Answers:
- Assign the integer 5 to the variable myVar
- Assign the pointer to function foo to myVar
- Do nothing
- Throw an exception
- None of the above
Answers:
- prepare ()
- open ()
- init ()
- build ()
- None of the above
Answers:
- Yes
- No
Answers:
- myReq.request();
- myReq.get();
- myReq.post(null);
- myReq.send(null);
- myReq.sendRequest(null);
Answers:
- Yes
- No
Answers:
- 100
- 200
- 300
- 501
- 500
Answers:
- The client machine running the Web Browser
- The server serving the JavaScript
- A central JavaScript server like root DNS
- None of the above
No comments:
Post a Comment