0% found this document useful (0 votes)
221 views

AtoZInternetProgramming2 (PHP) MCQs

This document contains multiple choice questions (MCQs) about various topics related to web technologies including PHP, cookies, variables, dates and times, sessions, JavaScript, and more. There are over 100 questions in total across different sections. The MCQs cover technical concepts, syntax, functions, and terms for each topic. Answers are provided for some of the questions.

Uploaded by

geovonni.kavis
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
221 views

AtoZInternetProgramming2 (PHP) MCQs

This document contains multiple choice questions (MCQs) about various topics related to web technologies including PHP, cookies, variables, dates and times, sessions, JavaScript, and more. There are over 100 questions in total across different sections. The MCQs cover technical concepts, syntax, functions, and terms for each topic. Answers are provided for some of the questions.

Uploaded by

geovonni.kavis
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 83

Chapter 1: Web Techniques

MCQs on Cookies

MCQ: In PHP, cookies are set by using the


A. setcookie ( ) function
B. set ( ) function
C.cookie_set ( ) function
D.None of them

Answer
MCQ: Name, value, expire, patrh, httponly, domain,
secure all of these are arguments of
A. session ( ) function
B. setcookie ( ) function
C.reset_cookie ( ) function
D.None of them
Answer
MCQ: The secure ( ) argument in setcookie function
returns result
A. In integer form
B. In string form
C.In boolean form
D.None of them
Answer
MCQ: In PHP4.1 and later versions, the cookies
name/value pair are added to the
A. Superglobal array
B. $_COOKIE
C.Global function
D.Both A and B.
---------------Answers
(a,b,c,d)_________________________
MCQs on PHP Variables PDF Online Download

MCQ: All variables in PHP are denoted by


A. Dollar sign $
B. Hash sign #
C.Asterisk sign *
D.Percent sign %
Answer
MCQ: All variables in PHP are assigned with the
A. Hash sign #
B. Dollar sign $
C.Assignment sign =
D.None of them
Answer
-----------
Answer(a,c)__________________________________________
_
MCQs on Date and Time Functions PDF Online
Download

MCQ: How many types of calendars are offered by PHP?


A. 2
B. 3
C.4
D.5
Answer
MCQ: Which from the following calendar is offered by
PHP?
A. Julian
B. Unixian
C.Jewish
D.All of them
Answer
MCQ: Which function is used to return date information?
A. date ( )
B. time_date ( )
C.getdate ( )
D.All of them
Answer
MCQ: A large number of PHP functions are duplicated
from
A. Windows
B. Macintosh
C.Unix
D.All of them
Answer
MCQ: mktime ( ) function allows you to convert any date
into a
A. String
B. Characters
C.Timestamp
D.None of them
-----------------------
answer(d,d,c,c,c)__________________

MCQs on Environment Variables PDF Online Download

MCQ: What is included in phpinfo ( ) function with the


release of PHP5.2.1 version?
A. A header tag
B. A footer tag
C.A Meta tag
D.None of them
------------answer(c)____________________________________
MCQs on How Sessions Work in PHP PDF Online
Download

MCQ: When a session ia active, PHP provides a special


constant called
A. SID
B. CID
C.DID
D.None of them
Answer
MCQ: If you want PHP to transparently handle passing
session variables for you when cookies are not available,
you have to configure
A. enable-trans-sid option
B. enable-track-vars option
C.disable-tans-vars option
D.Both A and B
Answer
MCQ: The $_SESSION array is one of the superglobal
variables introduced in
A. PHP2.1
B. PHP3
C.PHP4.1
D.PHP6
Answer
MCQ: The meaning of superglobal arrays is it can be
A. Referenced inside a function
B. Referenced outside of function
C.Used without declaring global first
D.All of them
---------------
answer(a,d,c,d)__________________________

MCQs on PHP Superglobal Arrays PDF Online


Download

MCQ: For accessing global variables anywhere from the


script, PHP uses
A. Get and Post Methods
B. Functions
C.Superglobal Arrays
D.None of them
Answer
MCQ: $GLOBALS, $_SERVER, $_REQUEST, $_POST,
$_GET, $_FILES, $_COOKIE, $_SESSION all are
example of
A. Super array
B. Global variables
C.Local variables
D.None of them
Answer
MCQ: In PHP6 the Register_ globals are
A. Improved
B. Updated
C.Changed
D.Officially gone
Answer
MCQ: The PHP stores all global variables in an array
called
A. $GLOBAL_ARRAY [ ]
B. $G_ARRAY [ ]
C.$GLOBALS [ ]
D.$GLOB_ARRAY [ ]
Answer
MCQ: Superglobal array was introduced in
A. PHP3
B. PHP4
C.PHP5
D.PHP6
E. -----------------
answer(c,b,d,c,b)___________________________
MCQs on Sessions and PHP PDF Online Download

MCQ: A period of time during which a particular person,


views a number of web pages at a particular machine is
called as
A. Session
B. Cookies
C.Parsing
D.None of them
Answer
MCQ: HTTP protocols by which browsers talk to a web
server is
A. Valueless
B. Stateless
C.Useless
D.None of them
Answer
---------------
answer(a,b)_________________________________________

MCQs on Simple Session Code PDF Online Download

MCQ: Using $_SESSION, $HTTP_SESSION_VARS


functions can be dangerous, so that you can use
A. session_destroy ( )
B. session_unset ( )
C.set ( )
D.None of them
Answer
MCQ: A function that takes no argument s and return a
string, which is unique key corresponding to a particular
session
A. session_name ( )
B. session_params ( )
C.session_id ( )
D.id ( )
Answer
MCQ: To initiate a session which function is used?
A. start ( )
B. s_start ( )
C.session_start ( )
D.session_str ( )
Answer
MCQ: If you want to free all the variables in a session,
which function you can use
A. session_destroy ( )
B. session_unset ( )
C.set ( )
D.All of them
Answer
MCQ: session_unset ( ) takes
A. 1 argument
B. 2 arguments
C.3 arguments
D.No argument
Answer
---------
answer(b,c,c,b,d)______________________________________
__

MCQs on Stateless HTTP PDF Online Download

MCQ: The HTTP protocol is stateless because a plain


HTML page is not capable of
A. Receiving information from other pages
B. Supporting php
C.Supporting web services
D.All of them
-----------------
answer(a)__________________________________
-------------------------_-------------------------------------------_-------------
---------------------++++

Chapter. 5 JavaScript
1. Why so JavaScript and Java have similar name?
A. JavaScript is a stripped-down version of Java
B. JavaScript's syntax is loosely based on Java's
C. They both originated on the island of Java
D. None of the above
Ans: B

2. When a user views a page containing a JavaScript


program, which machine actually executes the script?
A. The User's machine running a Web browser
B. The Web server
C. A central machine deep within Netscape's corporate
offices
D. None of the above
Ans: A

3. ______ JavaScript is also called client-side


JavaScript.
A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: B

4. __________ JavaScript is also called server-side


JavaScript.
A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: C

5. What are variables used for in JavaScript Programs?


A. Storing numbers, dates, or other values
B. Varying randomly
C. Causing high-school algebra flashbacks
D. None of the above
Ans: A

6. _____ JavaScript statements embedded in an HTML


page can respond to user events such as mouse-clicks,
form input, and page navigation.
A. Client-side
B. Server-side
C. Local
D. Native
Ans: A
7. What should appear at the very end of your
JavaScript?
The <script LANGUAGE="JavaScript">tag
A. The </script>
B. The <script>
C. The END statement
D. None of the above
Ans: A

8. Which of the following can't be done with client-


side JavaScript?
A. Validating a form
B. Sending a form's contents by email
C. Storing the form's contents to a database file on the
server
D. None of the above
Ans: C

9. Which of the following are capabilities of functions


in JavaScript?
A. Return a value
B. Accept parameters and Return a value
C. Accept parameters
D. None of the above
Ans: C

10. Which of the following is not a valid JavaScript


variable name?
A. 2names
B. _first_and_last_names
C. FirstAndLast
D. None of the above
Ans: A

11. ______ tag is an extension to HTML that can


enclose any number of JavaScript statements.
A. <SCRIPT>
B. <BODY>
C. <HEAD>
D. <TITLE>
Ans: A

12. How does JavaScript store dates in a date object?


A. The number of milliseconds since January 1st, 1970
B. The number of days since January 1st, 1900
C. The number of seconds since Netscape's public stock
offering.
D. None of the above
Ans: A

13. Which of the following attribute can hold the


JavaScript version?
A. LANGUAGE
B. SCRIPT
C. VERSION
D. None of the above
Ans: A

14. What is the correct JavaScript syntax to write


"Hello World"?
A. System.out.println("Hello World")
B. println ("Hello World")
C. document.write("Hello World")
D. response.write("Hello World")
Ans: C

15. Which of the following way can be used to


indicate the LANGUAGE attribute?
A. <LANGUAGE="JavaScriptVersion">
B. <SCRIPT LANGUAGE="JavaScriptVersion">
C. <SCRIPT LANGUAGE="JavaScriptVersion"> JavaScript
statements…</SCRIPT>
D. <SCRIPT
LANGUAGE="JavaScriptVersion"!> JavaScript
statements…</SCRIPT>
Ans: C

16. Inside which HTML element do we put the


JavaScript?
A. <js>
B. <scripting>
C. <script>
D. <javascript>
Ans: C
17. What is the correct syntax for referring to an
external script called " abc.js"?
A. <script href=" abc.js">
B. <script name=" abc.js">
C. <script src=" abc.js">
D. None of the above
Ans: C

18. Which types of image maps can be used with


JavaScript?
A. Server-side image maps
B. Client-side image maps
C. Server-side image maps and Client-side image maps
D. None of the above
Ans: B

19. Which of the following navigator object properties


is the same in both Netscape and IE?
A. navigator.appCodeName
B. navigator.appName
C. navigator.appVersion
D. None of the above
Ans: A

20. Which is the correct way to write a JavaScript


array?
A. var txt = new Array(1:"tim",2:"kim",3:"jim")
B. var txt = new Array:1=("tim")2=("kim")3=("jim")
C. var txt = new Array("tim","kim","jim")
D. var txt = new Array="tim","kim","jim"
Ans: C

21. What does the <noscript> tag do?


A. Enclose text to be displayed by non-JavaScript
browsers.
B. Prevents scripts on the page from executing.
C. Describes certain low-budget movies.
D. None of the above
Ans: A

22. If para1 is the DOM object for a paragraph, what is


the correct syntax to change the text within the
paragraph?
A. "New Text"?
B. para1.value="New Text";
C. para1.firstChild.nodeValue= "New Text";
D. para1.nodeValue="New Text";
Ans: B

23. JavaScript entities start with _______ and end


with _________.
A. Semicolon, colon
B. Semicolon, Ampersand
C. Ampersand, colon
D. Ampersand, semicolon
Ans: D

24. Which of the following best describes JavaScript?


A. a low-level programming language.
B. a scripting language precompiled in the browser.
C. a compiled scripting language.
D. an object-oriented scripting language.
Ans: D

25. Choose the server-side JavaScript object?


A. FileUpLoad
B. Function
C. File
D. Date
Ans: C

26. Choose the client-side JavaScript object?


A. Database
B. Cursor
C. Client
D. FileUpLoad
Ans: D

27. Which of the following is not considered a


JavaScript operator?
A. new
B. this
C. delete
D. typeof
Ans: B

28. ______method evaluates a string of JavaScript


code in the context of the specified object.
A. Eval
B. ParseInt
C. ParseFloat
D. Efloat
Ans: A

29. Which of the following event fires when the form


element loses the focus: <button>, <input>, <label>,
<select>, <textarea>?
A. onfocus
B. onblur
C. onclick
D. ondblclick
Ans: B

30. The syntax of Eval is ________________


A. [objectName.]eval(numeriC.
B. [objectName.]eval(string)
C. [EvalName.]eval(string)
D. [EvalName.]eval(numeriC.
Ans: B

31. JavaScript is interpreted by _________


A. Client
B. Server
C. Object
D. None of the above
Ans: A

32. Using _______ statement is how you test for a


specific condition.
A. Select
B. If
C. Switch
D. For
Ans: B

33. Which of the following is the structure of an if


statement?
A. if (conditional expression is true) thenexecute this
codeend if
B. if (conditional expression is true)execute this
codeend if
C. if (conditional expression is true) {then execute this
code>->}
D. if (conditional expression is true) then {execute this
code}
Ans: C

34. How to create a Date object in JavaScript?


A. dateObjectName = new Date([parameters])
B. dateObjectName.new Date([parameters])
C. dateObjectName := new Date([parameters])
D. dateObjectName Date([parameters])
Ans: A

35. The _______ method of an Array object adds


and/or removes elements from an array.
A. Reverse
B. Shift
C. Slice
D. Splice
Ans: D

36. To set up the window to capture all Click events,


we use which of the following statement?
A. window.captureEvents(Event.CLICK);
B. window.handleEvents (Event.CLICK);
C. window.routeEvents(Event.CLICK );
D. window.raiseEvents(Event.CLICK );
Ans: A

37. Which tag(s) can handle mouse events in


Netscape?
A. <IMG>
B. <A>
C. <BR>
D. None of the above
Ans: B
38. ____________ is the tainted property of a
window object.
A. Pathname
B. Protocol
C. Defaultstatus
D. Host
Ans: C

39. To enable data tainting, the end user sets the


_________ environment variable.
A. ENABLE_TAINT
B. MS_ENABLE_TAINT
C. NS_ENABLE_TAINT
D. ENABLE_TAINT_NS
Ans: C

40. In JavaScript, _________ is an object of the


target language data type that encloses an object of
the source language.
A. a wrapper
B. a link
C. a cursor
D. a form
Ans: A

41. When a JavaScript object is sent to Java, the


runtime engine creates a Java wrapper of type
___________
A. ScriptObject
B. JSObject
C. JavaObject
D. Jobject
Ans: B

42. _______ class provides an interface for invoking


JavaScript methods and examining JavaScript
properties.
A. ScriptObject
B. JSObject
C. JavaObject
D. Jobject
Ans: B

43. _________ is a wrapped Java array, accessed


from within JavaScript code.
A. JavaArray
B. JavaClass
C. JavaObject
D. JavaPackage
Ans: A

44. A ________ object is a reference to one of the


classes in a Java package, such as netscape.javascript .
A. JavaArray
B. JavaClass
C. JavaObject
D. JavaPackage
Ans: B

45. The JavaScript exception is available to the Java


code as an instance of __________
A. netscape.javascript.JSObject
B. netscape.javascript.JSException
C. netscape.plugin.JSException
D. None of the above
Ans: B

46. To automatically open the console when a


JavaScript error occurs which of the following is added
to prefs.js?
A. user_pref(" javascript.console.open_on_error", false);
B. user_pref("javascript.console.open_error ", true);
C. user_pref("javascript.console.open_error ", false);
D. user_pref("javascript.console.open_on_error", true);
Ans: D

47. To open a dialog box each time an error occurs,


which of the following is added to prefs.js?
A. user_pref("javascript.classic.error_alerts", true);
B. user_pref("javascript.classic.error_alerts ", false);
C. user_pref("javascript.console.open_on_error ", true);
D. user_pref("javascript.console.open_on_error ", false);
Ans: A
48. The syntax of a blur method in a button object is
______________
A. Blur()
B. Blur(contrast)
C. Blur(value)
D. Blur(depth)
Ans: A

49. The syntax of capture events method for


document object is ______________
A. captureEvents()
B. captureEvents(args eventType)
C. captureEvents(eventType)
D. captureEvents(eventVal)
Ans: C

50. The syntax of close method for document object


is ______________
A. Close(doC.
B. Close(object)
C. Close(val)
D. Close()
Ans: D

51. <script type="text/javascript">


x=4+"4";
document.write(x);
</script>

Output------?
A. 44
B. 8
C. 4
D. Error output
Ans: A

52. Is it possible to nest functions in JavaScript?


A. True
B. False
Ans: A

53. <script>
document.write(navigator.appCodeName);
</script>
A. get code name of the browser of a visitor
B. set code name of the browser of a visitor
C. None of the above
Ans: A

54. Scripting language are


A. High Level Programming language
B. Assembly Level programming language
C. Machine level programming language
Ans: A
55. Which best explains getSelection()?
A. Returns the VALUE of a selected OPTION.
B. Returns document.URL of the window in focus.
C. Returns the value of cursor-selected text
D. Returns the VALUE of a checked radio input.
Ans: C

56. Choose the client-side JavaScript object:


A. Database
B. Cursor
C. Client
D. FileUpLoad
Ans: D

57. What is mean by "this" keyword in javascript?


A. It refers current object
B. It referes previous object
C. It is variable which contains value
D. None of the above
Ans: A

58. In JavaScript, Window.prompt() method return


true or false value ?
A. False
B. True
Ans: A

59. <script language="javascript">


function x()
{
document.write(2+5+"8");
}
</script>
A. 258
B. Error
C. 7
D. 78
Ans: D

60. <script type="text/javascript">


var s = "9123456 or 80000?";
var pattern = /\d{4}/;
var output = s.match(pattern);
document.write(output);
</script>
A. 9123
B. 91234
C. 80000
D. None of the above
Ans: A

------------------------------------------------------------------------------------
----;;-;;;--

Chapter 6: AJAX
What is AJAX ?
A. is a program
B. is a country name
C. is a football club name
Ans: A
Collection from: www.cs-mcqs.blogspot.com
2- What sever support AJAX ? | Ajax
A. SMTP
B. WWW
C. HTTP
Ans: C
Collection from: www.cs-mcqs.blogspot.com
3- AJAX Stands for: | Ajax
A. Asynchronous Javascript and XML
B. Abstract JSON and XML
C. Another Java Abstraction for X-Windows
D. Another Java and XML Library
Ans: A
Collection from: www.cs-mcqs.blogspot.com
4- What makes Ajax unique? Ajax
A. It works as a stand-alone Web-development
tool.
B. It works the same with all Web browsers.
C. It uses C++ as its programming language.
D. It makes data requests asynchronously.
Ans: D
Collection from: www.cs-mcqs.blogspot.com
5- What does the XMLHttpRequest object
accomplish in Ajax? | Ajax
A. It's the programming language used to develop
Ajax applications.
B. It provides a means of exchanging structured
data between the Web server and client.
C. It provides the ability to asynchronously
exchange data between Web browsers and a Web
server.
D. It provides the ability to mark up and style the
display of Web-page text.
Ans: C
Collection from: www.cs-mcqs.blogspot.com
6- Of the following technologies, which one
provides the ability to dynamically interact with
Web page layout? Ajax
A. JavaScript.
B. XML.
C. Document Object Model.
D. HTML.
Ans: C
Collection from: www.cs-mcqs.blogspot.com
7- What is the first step in creating a Joke of the
Day application? | Ajax
A. Create the application's text file.
B. Write the application's HTML.
C. Turn the HTML application into an Ajax
application.
D. Upload the application to a Web server.
Ans: B
Collection from: www.cs-mcqs.blogspot.com
8- Ajax stands for Synchronous JavaScript and
XML. | Ajax
A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
9- Ajax is a programming language. | Ajax
A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
10- Regarding the XMLHttpRequest Object, does
the order in which one calls the "open" method and
assign a function to the "onreadystatechange"
event handler matter? | Ajax
A. Yes
B. No
Ans: B
Collection from: www.cs-mcqs.blogspot.com
11- Can a call to the "send" method fire an error
(assuming the user's browser supports the
XMLHttpRequest Object and the "send" method )?
| Ajax
A. Yes
B. No
Ans: B
Collection from: www.cs-mcqs.blogspot.com
12- ActiveX can be disabled via browser settings. |
Ajax
A. True
B. False
Ans: A
Collection from: www.cs-mcqs.blogspot.com
13- The XMLHttpRequest object can be disabled via
browser settings. | Ajax

A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
14- Assuming that "xmlhttp" is a user-defined
variable that carrys the Ajax requesting object,
xmlhttp.status can carry a value of 4 after a
successful request. | Ajax
A. TrueB. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
15- The XMLHttpRequest object supports a method
called "quit". | Ajax
A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
16- Assuming that "xmlhttp" is a user-defined
variable that carrys the Ajax requesting object,
xmlhttp.status can carry a value of 0 after a
successful request. | Ajax
A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
17- The XMLHttpRequest object can be used on
subdomain1.mysite.com to request a page located
at subdomain2.mysite.com according to the
specification. | Ajax
A. True
B. False
Ans: B
Collection from: www.cs-mcqs.blogspot.com
18- What combination of technologies gives AJAX
its name? | Ajax
A. ASP and XAML
B. Asynchronous JavaScript and XML
C. Autonomic Computing and DHTML
D. Atlas and XML
Ans: B
Collection from: www.cs-mcqs.blogspot.com
19- Which one of these legendary Greek mythical
figures or places is the code name for Microsoft's
version of AJAX ? | Ajax

A. Oracle
B. Atlas
C. Hercules
D. Delphi
Ans: B
Collection from: www.cs-mcqs.blogspot.com
21- Which Web browser is the least optimized for
Microsoft's version of AJAX? | Ajax
A. Firefox
B. Opera
C. Safari
D. Internet Explorer
Ans: C
Collection from: www.cs-mcqs.blogspot.com
22- Which one of these technologies is NOT used in
AJAX? | Ajax
A. CSS
B. DOM
C. DHTML
D. FLASH
Ans: D
Collection from: www.cs-mcqs.blogspot.com
23- AJAX comes in _____. | Ajax

A. 2003
B. 2005
C. 2004
D. 2006
Ans: B
Collection from: www.cs-mcqs.blogspot.com
24- AJAX made popular by | Ajax
A. Microsoft
B. IBM
C. Sun Micro system
D. Google
Ans: D
Collection from: www.cs-mcqs.blogspot.com
25- AJAX based on ______ . | Ajax
A. JavaScript and XML
B. JavaScript and Java
C. VBScript and XML
D. JavaScript and HTTP requests
Ans: A
Collection from: www.cs-mcqs.blogspot.com
26- Using AJAX we can made our web page. | Ajax
A. more interactive and faster
B. easy to connect web page with server
C. more dynamic
Ans: A
Collection from: www.cs-mcqs.blogspot.com
27- What does the <noscript> tag do? | Ajax
A. Enclose text to be displayed by non-JavaScript
browsers.
B. Prevents scripts on the page from executing.
C. Describes certain low-budget movies.
D. None of the above
Ans: A
Collection from: www.cs-mcqs.blogspot.com
28- Why so JavaScript and Java have similar
name? | Ajax
A. JavaScript is a stripped-down version of Java
B. JavaScript's syntax is loosely based on Java's
C. They both originated on the island of Java
D. None of the above
Ans: B
Collection from: www.cs-mcqs.blogspot.com
29- When a user views a page containing a
JavaScript program, which machine actually
executes the script? | Ajax
A. The User's machine running a Web browser
B. The Web server
C. A central machine deep within Netscape's
corporate offices
D. None of the above
Ans: A
Collection from: www.cs-mcqs.blogspot.com
30- _____ JavaScript is also called client-side
JavaScript. | Ajax

A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: B
Collection from: www.cs-mcqs.blogspot.com
31- _______ JavaScript is also called server-side
JavaScript. | Ajax
A. Microsoft
B. Navigator
C. LiveWire
Ans: C
Collection from: www.
. What is AJAX ?
A. is a programe
B. is a country name
C. is a football club name
Ans: A

2. What sever support AJAX ?


A. SMTP
B. WWW
C. HTTP
Ans: C

3. AJAX Stands for:


A. Asynchronous Javascript and XML
B. Abstract JSON and XML
C. Another Java Abstraction for X-Windows
D. Another Java and XML Library
Ans: A

4. What makes Ajax unique?


A. It works as a stand-alone Web-development tool.
B. It works the same with all Web browsers.
C. It uses C++ as its programming language.
D. It makes data requests asynchronously.
Ans: D

5. What does the XMLHttpRequest object accomplish in


Ajax?
A. It's the programming language used to develop Ajax
applications.
B. It provides a means of exchanging structured data
between the Web server and client.
C. It provides the ability to asynchronously exchange
data between Web browsers and a Web server.
D. It provides the ability to mark up and style the
display of Web-page text.
Ans: C

6. ________ Of the following technologies, which one


provides the ability to dynamically interact with Web
page layout?
A. JavaScript.
B. XML.
C. Document Object Model.
D. HTML.
Ans: C

7. What is the first step in creating a Joke of the Day


application?
A. Create the application's text file.
B. Write the application's HTML.
C. Turn the HTML application into an Ajax application.
D. Upload the application to a Web server.
Ans: B

8. Ajax stands for Synchronous JavaScript and XML.


A. True
B. False
Ans: B

9. Ajax is a programming language.


A. True
B. False
Ans: B

10. Regarding the XMLHttpRequest Object, does the


order in which one calls the "open" method and assign
a function to the "onreadystatechange" event handler
matter?
A. Yes
B. No
Ans: B

11. Can a call to the "send" method fire an error


(assuming the user's browser supports the
XMLHttpRequest Object and the "send" method )?
A. Yes
B. No
Ans: B

12. ActiveX can be disabled via browser settings.


A. True
B. False
Ans: A
13. The XMLHttpRequest object can be disabled via
browser settings.
A. True
B. False
Ans: B

14. Assuming that "xmlhttp" is a user-defined variable


that carrys the Ajax requesting object, xmlhttp.status
can carry a value of 4 after a successful request.
A. True
B. False
Ans: B

15. The XMLHttpRequest object supports a method


called "quit".
A. True
B. False
Ans: B

16. Assuming that "xmlhttp" is a user-defined variable


that carrys the Ajax requesting object, xmlhttp.status
can carry a value of 0 after a successful request.
A. True
B. False
Ans: B

17. The XMLHttpRequest object can be used on


subdomain1.mysite.com to request a page located at
subdomain2.mysite.com according to the specification.
A. True
B. False
Ans: B

18. What combination of technologies gives AJAX its


name?
A. ASP and XAML
B. Asynchronous JavaScript and XML
C. Autonomic Computing and DHTML
D. Atlas and XML
Ans: B

19. Which one of these legendary Greek mythical


figures or places is the code name for Microsoft's
version of AJAX ?
A. Oracle
B. Atlas
C. Hercules
D. Delphi
Ans: B

20. Which Web browser is the least optimized for


Microsoft's version of AJAX?
A. Firefox
B. Opera
C. Safari
D. Internet Explorer
Ans: C

21. Which one of these technologies is NOT used in


AJAX?
A. CSS
B. DOM
C. DHTML
D. Flash
Ans: D

22. AJAX comes in ____.


A. 2003
B. 2005
C. 2004
D. 2006
Ans: B

23. AJAX made popular by


A. Microsoft
B. IBM
C. Sun Microsystem
D. Google
Ans: D

24. AJAX based on


A. JavaScript and XML
B. JavaScript and Java
C. VBScript and XML
D. JavaScript and HTTP requests
Ans: A

25. Using AJAX we can made our web page


a. more interactive and faster
b. easy to connect web page with server
c. more dynamic
Ans: A

26. What does the tag do?


A. Enclose text to be displayed by non-JavaScript
browsers.
B. Prevents scripts on the page from executing.
C. Describes certain low-budget movies.
D. None of the above
Ans: A

27. Why so JavaScript and Java have similar name?


A. JavaScript is a stripped-down version of Java
B. JavaScript's syntax is loosely based on Java's
C. They both originated on the island of Java
D. None of the above
Ans: B

28. When a user views a page containing a JavaScript


program, which machine actually executes the script?
A. The User's machine running a Web browser
B. The Web server
C. A central machine deep within Netscape's corporate
offices
D. None of the above
Ans: A

29. _____ JavaScript is also called client-side


JavaScript.
A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: B

30 _______ JavaScript is also called server-side


JavaScript
A. Microsoft
B. Navigator
C. LiveWire
Ans: C

at 09:12
Email ThisBlogThis!Share to TwitterShare to
FacebookShare to Pinterest
------------------------------------------------------------------------------
-------------------------------+-+--------+++

Chapter 2: Email Handling with Php


This set of PHP Multiple Choice Questions & Answers
(MCQs) focuses on “Networking with PHP”.

1. What is the full form of DNS?


a)DigitalNetworkSystem
b)DomainNetworkSystem
c)DigitalNameSystmem
d)DomainNameSystem
View Answer
Answer: d
Explanation: DNS stands for domain name system. It is
the way that internet domain names are located and
translated into internet protocol (IP) addresses. For
example, if someone types abc.com into the web browser,
a server behind the scenes will map that name to the IP
address 206.16.49.139.

advertisement

2. Which one of the following function checks for the


existence of DNS records?
a)checkdns()
b)checkdnsr()
c)checkdnsrr()
d)checkdnsa()
View Answer
Answer: c
Explanation: The function checkdnsrr() is used to check
DNS records for type corresponding to host. DNS records
are checked based on the supplied host value and
optional DNS resource record type, returning TRUE if any
records are located and FALSE otherwise.

3. Which one of the following function is used to return an


array consisting of various DNS resource records pertinent
to a specific domain?
a)dns_get_record()
b)dns_record()
c)dnsrr_get_record()
d)dnsrr_record()
View Answer
Answer: a
Explanation: The function dns_get_record() is used to get
the DNS resource records associated with the specified
hostname. This function is used to return an array
consisting of various DNS resource records pertinent to a
specific domain.

4. Which one of the following function is used to retrieve the


MX records for the domain specified by hostname?
a)getmx()
b)retrieve_mx()
c)getmxrr()
d)retrieve_mxrr()
View Answer
Answer: c
Explanation: The function getmxrr() returns the MX
records for the specified internet host name. This function
is used to retrieve the MX records for the domain specified
by hostname.

5. What is the default port number of HTTPs?


a)70
b)80
c)90
d)100
View Answer
Answer: b
Explanation: By default, The port number HTTP uses is
port 80 and HTTPS uses port 443, but a URL like
http://www.abc.com:8080/path/ specifies that the web
browser connects instead to port 8080 of the HTTP
servers.

advertisement

6. Which one of the following function returns the port


number of a specified service?
a)getportname()
b)getservername()
c)getserverbyname()
d)getservbyname()
View Answer
Answer: d
Explanation: The function fgetservbyname() returns the
port number for a given Internet service and protocol.
Example-getservbyname(“http”,”tcp”) will return 80.

7. Which one of the following statements can be used to


establish port 80 connection with www.nachi.com?
a)fsockopen(“www.nachi.com”, 80);
b)sockopen(80,”www.nachi.com”);
c)fsockopen(80,”www.nachi.com”);
d)sockopen(“www.nachi.com”, 80);
View Answer
Answer: a
Explanation: The fsockopen() function establishes a
connection to the resource designated by target on port.

8. Which one of the following function is used to send an


email using PHP script?
a)mail_send()
b)send_mail()
c)mailrr()
d)mail()
View Answer
Answer: d
Explanation: The function mail() allows you to send emails
directly from a script. Using mail(string to, string subject,
string message), you can send any mail.

9. How many configuration directives pertinent to PHP’s


mail function are available?
a)4
b)5
c)6
d)7
View Answer
Answer: b
Explanation: They are- SMTP, sendmail_from,
sendmail_path, smtp_port, mail.force_extra_parameters.

advertisement

10. Which of the following statements is used to add an


attachment to the mail?
a)$mimemail->attachment(‘attachment.pdf’);
b)$mimemail=>attachment(‘attachment.pdf’);
c)$mimemail->addAttachment(‘attachment.pdf’);
d)$mimemail=>addAttachment(‘attachment.pdf’);
View Answer
Answer: c
Explanation: Call the Mail_Mime object’s addAttachment()
method passing in the attachment name and extension.

------------------------------------------------------------------------------
----------+----------------
Chapter 4: XML

XML Multiple Choice Questions and Answers

1. What does XML stand for?


A. eXtra Modern Link
B. eXtensible Markup Language
C. Example Markup Language
D. X-Markup Language
Ans: B

2. What is the correct syntax of the declaration


which defines the XML version?:
A. <xml version="A.0" />
B. <?xml version="A.0"?>
C. <?xml version="A.0" />
D. None of the above
Ans: B

3. Which statement is true?


A. All the statements are true
B. All XML elements must have a closing tag
C. All XML elements must be lower case
D. All XML documents must have a DTD
Ans: B
4. Is it easier to process XML than HTML?
A. Yes
B. No
C. Somtimes
D. Cant say
Ans: A

5. Which of the following programs support XML or


XML applications?:
A. Internet Explorer 5.5
B. Netscape D.7
C. RealPlayer.
D. both A and B
Ans: D

6. Kind of Parsers are


A. well-formed
B. well-documented
C. non-validating and validating
D. none of the above
Ans: C

7. Well formed XML document means


A. it contains a root element
B. it contain an element
C. it contains one or more elements
D. must contain one or more elements and root
element must contain all other elements
Ans: D

8. Comment in XML document is given by


A. <?-- -->
B. <!-- --!>
C. <!-- -->
D. </-- -- >
Ans: C

9. When processing an output XML, "new line"


symbols
A. are copied into output "as is", i.e. "CR+LF" for
Windows, CR for Macintosh, LF for Unix.
B. are converted to single LF symbol
C. are converted to single CR symbol
D. are discarded
Ans: B

10. Which of the following strings are a correct XML


name?
A. _myElement
B. my Element
C. #myElement
D. None of the above
Ans: A

11. Which of the following strings are a correct XML


name?
A. xmlExtension
B. xslNewElement
C. XMLElement#123
D. All
Ans: B

12. Which of the following XML fragments are well-


formed?
A. <?xml?>
B. <?xml version="A.0"?>
C. <?xml encoding="JIS"?>
D. <?xml encoding="JIS" version="A.0"?>
Ans: B

13. What are the predefined attributes


A. xml:lang
B. xml:space
C. both
D. none.
Ans: C

14. Kind of Parsers are


A. well-formed
B. validating
C. non-validating
D. Both B & C
Ans: D
15. Valid XML document means (most appropriate)
A. the document has root element
B. the document contains atleast one or more root
element
C. the XML document has DTD associated with it & it
complies with that DTD
D. Each element must nest inside any enclosing
element property
Ans: C

16. XML uses the features of


A. HTML
B. XHTML
C. VML
D. SGML
Ans: D

17. XML document can be viewed in


A. IE C.0
B. IE B.0
C. IE 6.0
D. IE X.0
Ans: C

18. There is a way of describing XML data, how?


A. XML uses a DTD to describe the data
B. XML uses XSL to describe data
C. XML uses a description node to describe data
D. Both A and C
Ans: D

19. What does DTD stand for?


A. Direct Type Definition
B. Document Type Definition
C. Do The Dance
D. Dynamic Type Definition
Ans: B

20. DTD includes the specifications about the


markup that can be used within the document, the
specifications consists of all EXCEPT
A. the browser name
B. the size of element name
C. entity declarations
D. element declarations
Ans: A

21. Which of the following XML documents are well-


formed?
A. <firstElement>some text goes here
<secondElement>another text goes
here</secondElement>
</firstElement>
B. <firstElement>some text goes here</firstElement>
<secondElement> another text goes
here</secondElement>
C. <firstElement>some text goes here
<secondElement> another text goes
here</firstElement>
</secondElement>
D. </firstElement>some text goes here
</secondElement>another text goes here
<firstElement>
Ans: B

22. Which of the following XML fragments are well-


formed?
A. <myElement myAttribute="someValue"/>
B. <myElement myAttribute=someValue/>
C. <myElement myAttribute=’someValue’>
D. <myElement myAttribute="someValue’/>
Ans: A

23. How can we make attributes have multiple


values:
A. <myElement myAttribute="value1 value2"/>
B. <myElement myAttribute="value1"
myAttribute="value2"/>
C. <myElement myAttribute="value1, value2"/>
D. attributes cannot have multiple values
Ans: D

24. Which of the following XML fragments are well-


formed?
A. <myElement myAttribute="value1 <= value2"/>
B. <myElement myAttribute="value1 & value2"/>
C. <myElement myAttribute="value1 > value2"/>
D. None of the above
Ans: C

25. The use of a DTD in XML development is:


A. required when validating XML documents
B. no longer necessary after the XML editor has been
customized
C. used to direct conversion using an XSLT processor
D. a good guide to populating a templates to be filled
in when generating an XML document automatically
Ans: A

26. Parameter entities can appear in


A. xml file
B. dtd file
C. xsl file
D. Both 1 and 2
Ans: B

27. Attribute standalone="no" should be included in


XML declaration if a document:
A. is linked to an external XSL stylesheet
B. has external general references
C. has processing instructions
D. has an external DTD
Ans: D

28. In XML
A. the internal DTD subset is read before the external
DTD
B. the external DTD subset is read before the internal
DTD
C. there is no external type of DTD
D. there is no internal type of DTD
Ans: A

29. Disadvantages of DTD are


(i)DTDs are not extensible
(ii)DTDs are not in to support for namespaces
(iii)there is no provision for inheritance from one DTDs
to another

A. (i) is correct
B. (i),(ii) are correct
C. (ii),(iii) are correct
D. (i),(ii),(iii) are correct
Ans: D

30. To use the external DTD we have the syntax


A. <?xml version=”A.0” standalone=”no”?>
<! DOCTYPE DOCUMENT SYSTEM “order.dtd”?>
B. <?xml version=”A.0” standalone=”yes”?>
<! DOCTYPE DOCUMENT SYSTEM “order.dtd”?>
(3 )<?xml version=”A.0” standalone=”no”?>
<! DOCTYPE DOCUMENT “order.dtd”?>
D. <?xml version=”A.0” standalone=”yes”?>
<! DOCTYPE DOCUMENT SYSTEM “order.dtd”?>
Ans: A

31. To add the attribute named Type to the


<customer> tag the syntax will be
A. <customer attribute Type=”exelent”>
B. <customer Type attribute =”exelent”>
C. <customer Type attribute_type=”exelent”>
D. <customer Type=” exelent” >
Ans: D

32. The syntax for parameter entity is


A. <! ENTITY % NAME DEFINITION>
B. < ENTITY % NAME DEFINITION>
C. <! ENTITY $ NAME DEFINITION>
D. < ENTITY % NAME DEFINITION>
Ans: A

33. You can name the schema using the name


attribute like
A. <schema attribute=”schema1”>
B. <schema nameattribute=”schema1”>
C. <schema nameattri=”schema1”>
D. <schema name=”schema1”>
Ans: D

34. The default model for complex type, in XML


schemas for element is
A. textOnly
B. elementOnly
C. no default type
D. both 1 & 2
Ans: B

35. Microsoft XML Schema Data types for


Hexadecimal digits representating octates
A. UID
B. UXID
C. UUID
D. XXID
Ans: C

36. A schema describes


(i) grammer
(ii) vocabulary
(iii) structure
(iv) datatype of XML document

A. (i) & (ii) are correct


B. (i),(iii) ,(iv) are correct
C. (i),(ii),(iv) are correct
D. (i),(ii),(iii),(iv) are correct
Ans: D

37. Microsoft XML Schema Data Type “ boolean” has


values
A. True ,False
B. True ,False or 1,0
C. 1,0
D. any number other then zero and zero
Ans: C

38. Simple type Built into Schema “ data’ represent


a data in
A. MM-DD-YY
B. Dd-MM-YY
C. YY-MM-DD
D. YYYY-MM-DD
Ans: D

39. In simple Type Built into XML schema Boolean


type holds
A. True, False
B. 1,0
C. both A. & B.
D. True/False and any number except 0
Ans: C

40. In simple type built into XML schema type flat


has single precision of ________ floating point
A. 16 bit
B. 32 bit
C. 8 bit
D. 4 bit
Ans: C

41. The XML DOM object is


A. Entity
B. Entity Reference
C. Comment Reference
D. Comment Data
Ans: B

42.Attribute of the document interface in DOM


is/are
(i)doctype
(ii)implementation
(iii)documentElement
which are read only attributes
A. (i) only
B. (ii) only
C. (ii),(iii) only
D. all
Ans: D

43. The default model for complex type, in XML


schemas for element is
A. textOnly
B. elementOnly
C. no default type
D. both a & b
Ans: B

44. To create a choise in XML schemas, we use the


A. <xsd:select> element
B. <xsd:multi> element
C. <xsd:choise> element
D. <xsd:single> element
Ans: C

45. The XML DOM object is


A. Entity
B. Entity Reference
C. Comment Reference
D. Comment Data
Ans: B

46. To create a data island we use the


_____________HTML element
A. <XML>
B. <dataisland>
C. <Island>
D. <XMLIsland>
Ans: A

47. To Bind the HTML elements with DSO we use


_________ attribute
A. DATASOURCE
B. DATAFIELD
C. DATASRC
D. DATAFLD
Ans: A,C

48. To bind the HTML element <INPUT> Type in text


with the datasource “ dsoCustomer” we use
A. <INPUT TYPE=”TEXT” DATAFIELD=”#dsoCustomer”>
B. <INPUT TYPE=”TEXT” DATASRC=” dsoCustomer”>
C. <INPUT TYPE=”TEXT” DATASRC=” #dsoCustomer” >
D. <INPUT TYPE=”TEXT” DATAFLD=” #dsoCustomer”>
Ans: C

49. XML DSOs has the property for the number of


pages of data the recordset contains
A. count
B. number
C. pageCount
D. pageNumber
Ans: C

50. Whats so great about XML?


A. Easy data exchange
B. High speed on network
C. Only B.is correct
D. Both A. & B.
Ans: D

51. For XML document to be valid


A. document need to be well formed also
B. document need not to be well formed
C. document need to be well formed & valid
D. document validity has no relationship with well
formedness
Ans: C

52. A textual object is a well formed XML document


if
(i) Taken as a whole it matches the production labeled
document.
(ii) Each of the parsed entity which is referenced
directly or indirectly within the document can be well
formed

A. (i) is correct
B. (ii)is correct
C. both are correct
Ans: C

53. <?xml version=” A.0” standalone=” yes”


encoding=”UTF-8” ?>
A. it shows that the version is A.0
B. shows thatit is standalone
C. the standalone is wrong
D. version attribute is not in XML
Ans: C

54. The attribute used to define a new namespace


is
A. XMLNS
B. XmlNameSpace
C. Xmlns
D. XmlNs
Ans: C

55. To match the root node in XMLT transform the


syntax will be
A. <xsl:template match=”Document”>
B. <xsl:template match=”Root”>
C. <xsl:template match=”RootNode”>
D. <xsl:template match=” /”>
Ans: D

56. To match the specific XML elements child like of


parent element is the syntax will be
A. <xsl:template match=”PLANET_NAME”>
B.<xsl:template match=”PLANET/NAME”>
C. <xsl:template match=”/NAME”>
D. <xsl:template match=”//”>
Ans: B

57. PI in XML specification stands for


A. C.14
B. priceless instruction
C. processing instruction
D. polymorphic inheritance
Ans: C

58. A validating XML application should be used


when:
A. the design demands that all elements use both
start and end tags
B. missing or out-of-place elements could cause
application errors
C. attribute values cannot refer to external entity
references
D. High performance is an important architectural
constraint
Ans: B

59. A DSO operates like


(a) data simulation object at server side
(b) dynamic source object at client side
(c) data source object at client side
(d) data simulation object at client side
Ans: C

60. The XSL formating object use to format a list is


A. list-block
B. list-item
C. list-item-body
D. list-item-label
Ans: A

61. The attribute used to define a new namespace


is
A. XMLNS
B. XmlNameSpace
C. Xmlns
D. XmlNs
Ans: C

62. Identify the most accurate statement about the


application of XML:
A. XML must be used to produce XML and HTML
output.
B. XML cannot specify or contain presentation
information.
C. XML is used to describe hierarchically organized
information.
D. XML performs the conversion of information
between different e-business applications.
Ans: C

63. The XSl formatting object which formats the


data and caption of a table is
A. table
B. table-content
C. table-text
D. none of the above
Ans: D

64. The XSL formating object which holds the


content of the table body
A. table
B. table-body
C. table-content
D. table-footer
Ans: B

65. The XSL formatting object which formats the


data in a table
A. table
B. table-body
C. title
D. table-content
Ans: A

66. The XSL formating object use to hold the


content of the label of a list item is
A. list-block
B. list item
C. list-item-body
D. list-item-label
Ans: D
67. The XSL formating object use to hold the
contents of the body of a list item is
A. list-block
B. list item
C. list-item-body
D. list-item-label
Ans: C

68. XSL has formatting object “ block”


A. is not supported in XSL
B. generates a block level reference area
C. create a display block
D. groups global declarations for a style sheet
Ans: B

69. XSL has “ block container” for formating the


document
A. to create a display block to format the titles
B. to create a display block to format the paragraphes
C. to create a display block to format the headlines &
figures
D. to create a block level reference area
Ans: D

70. The syntax for writing the minimum occurrence


for an element is
A. <xsd:element ref=” note” min=” 0” />
B. <xsd:elements ref=” note” min=” 0” />
C. <xsd:elements ref=” note” minOccur=”0” />
D. <xsd:elements ref=” note” minOccurs=” 0” />
Ans: D

71. The syntax for writing default values for


element is
A. <xsd:element name=”max” type=” xsd:integer”
value=” 100” />
B. <xsd:element name=”max” type=” xsd:integer”
fixValue=” 100” />
C. <xsd:element name=”max” type=” xsd:integer”
default=” 100” />
D. <xsd:element name=”max” type=” xsd:integer”
defaultval=” 100” />
Ans: C

72. To use XSLT in an XML system:


A. the input and output of the XSLT processor must be
unparsed XML documents
B. the input and output of the XSLT processor must be
a hierarchical tree representing an XML document
C. the XSLT processor must be called from a web
agent
D. the XSLT processor must be given the DTD as well
as the XML document instance
Ans: B

73. What is the role of the XPath language in XSL


processing?
A. XPath identifies the order or path of processing to
be followed as the XSL language is processed
B. XPath identifies locations in XML data to be
transformed in the source tree and the locations to be
generated in output tree specified in XSL translation
prescriptions
C. XPath identifies the path to be followed in the
execution of XSL translation prescriptions
D. XPath specifies which XSL transform files are to be
used in the translation of XML
Ans: B

74. Which statement correctly describes the


capabilities of the XSLT language?
A. XSLT uses the DTD to determine how XML
documents will be translated
B. XSLT specifies how a hierarchical trees,
representable by an XML document may be translated
into non-hierarchical formats
C. XSLT specifies how a hierarchical tree,
representable by an XML document, may be translated
into another hierarchical tree, also representable by
an XML document
D. XSLT specifies the formatting style to be used to
render an XML document
Ans: C
75. XSLT processors accept as input:
A. an XML conforming document file and an XSLT
specification file
B. only an XML document
C. only an XSLT specification
D. either an XML document or an XSLT specification
Ans: A

76. The transformation of XML document in to


another type of document by XSLT can be done by

(i)In the server


(ii)In the client
(iii)With a separate program

A. only(i) & (ii)


B. only (ii) & (iii)
C. all are correct
D. only (i) & (iii)
Ans: C

77: To match the root node in XMLT transform the


syntax will be

A. <xsl:template match=”Document”>
B. <xsl:template match=”Root”>
C. <xsl:template match=”RootNode”>
D. <xsl:template match=” /” >
Ans: D

78: To match the specific XML elements in XMLT the


syntax for given name “ rootnode” is

A. <xsl:template match=” root”>


B. <xsl:template match=” /”>
C. <xsl:template match=” rootnode” >
D. <xsl:template match=” //”>
Ans: C

79. To match the specific XML elements child like of


parent element is the syntax will be

A. <xsl:template match=”PLANET_NAME”>
B. <xsl:template match=” PLANET/NAME” >
C. <xsl:template match=” /NAME”>
D. <xsl:template match=” //”>
Ans: B

80. InXSLT style sheet we have syntax to match


elements with id as (if id is “ change” )

A. <xsl:template match=” id(‘change’)” >


B. <xsl:template match=” (change)”>
C. <xsl:template match=” change”>
D. <xsl:template match-id=”Change”>
Ans: A
81. To match the text node (in XSLT) the syntax will
be

A. <xsl:template match=” text”>


B. <xsl:template match-text=” text”>
C. <xsl:template match=text( )>
D. <xsl:template match=” text( )” >
Ans: D

82. An element declaration specifies

A. a single markup element


B. zmarkup elements
C. markup data
D. the document data
Ans: A

83. Well formed XML document means(most


appropriate)

A. it contains a root element


B. it contain an element
C. it contains one or more elements
D. must contain one or more elements and root
element must contain all other elements
Ans: D
84: Which of the following specify that the order
and content of "membership" is not important

A. <!ELEMENT membership NORULE>


B. <!ELEMENT membership EMPTY>
C. <!ELEMENT membership ALL>
D. <!ELEMENT membership ANY>
Ans: D

85: Which of the following is used to specify the


attribute list of an element

A. ATTLIST
B. ?ATTLIST
C. !ATTLIST
D. #ATTLIST
Ans: C

86: Which of the following instruct the browser


which stylesheet to use

A. <xml-stylesheet type="text/xsl" href="cd.xsl">


B. <xml-stylesheet type="text/xsl" xsl="cd.xsl">
C. <?xml-stylesheet type="text/xsl" href="cd.xsl"?>
D. <?xml-stylesheet type="text/xsl" xsl="cd.xsl"?>
Ans: C

88: Which of the following XSLT Patterns is used to


match any descendant nodes
A. /
B. //
C. .
D. ..
Ans: B

89: Which of the following XSLT Patterns is used to


match the parent node

A. /
B. //
C. .
D. ..
Ans: D

90: Which of the following is a valid XSLT iteration


command

A. for
B. for-all
C. for-each
D. in-turn
Ans: C

91.What is an advantage of XML compared to HTML?

A. XML works on more platforms.


B. XML is suited to using Web pages as front ends to
databases.
C. XML was designed for portable phones.
D. XML is simpler to learn than HTML.
Ans: B

92.The following best describes the development of


XML.

A. XML developed from HTML because WEB browsers


became more powerful.
B. XML is designed as a replacement because SGML
can not be used for document development.
C. XML builds on HTMLs ability to provide content to
virtually any audience by adding the power of
intelligent content.
D. XML is the modern replacement for HTML and
SGML, taking the good points from each, making both
of those languages obsolete.
Ans: C

93. The correct priority for implementing XML


based IETMs is :

A. Develop DTD, conduct a pilot project, create a


modular library, train staff.
B. Train staff, convert legacy documents, develop
DTD, create modular library.
C. Conduct pilot program, train staff, create modular
library, develop DTD
D. Conduct pilot program, train staff, develop DTD,
convert documents, purchace XML tools.
Ans: C

94. Which of the following statements is true:

A. XML is a direct subset of SGML


B. SGML is an application of HTML
C. XML is a kind of dynamic HTML
D. XHTML is XML rewritten in HTML
5. SGML and XML are the same thing
Ans: A

95. What is a qualified name?

A. Any name conforming to the XML Names


specification
B. A name having prefix and local name separated by
a colon
C. A name applying only to qualified elements and
attributes
D. None of the above
Ans: C

96. What is a NCName


A. A Non-Common Name
B. A Non-Conforming Name
C. A Non-Colonized Name
D. None of the above
Ans: C

97. Which of the following statements about XML


schemas is incorrect?
A. All XML documents must have a schema
B. Schemas can specify integer values
C. Schemas are defined by XSD tag
D. They offer more flexibility than DTDs
E. Schemas provide data oriented data types
Ans: A

You might also like