100 TOP WEB TECHNOLOGIES Multiple Choice Questions and Answers

WEB TECHNOLOGIES Multiple Choice Questions and Answers :-

1. Which of the following options is correct with regard to HTML?

(a) It is a modelling language
(b) It is a DTP language
(c) It is a partial programming language
(d) It is used to structure documents
(e) It is a scripting language.

2. Consider the following statement:
GET /cgi-bin/dispenser.pl&want=whatsnew.html HTTP/1.0

Which of the following options is a correct one?

(a) The above statement is a part of a request from a web client
(b) The above statement is a part of the input to a CGI program
(c) want is a variable and whatsnew.html is a value
(d) want is a variable and whatsnew.html HTTP/1.0 is the value
(e) dispenser.pl may be a CGI program.

3. When trying to access a URL, the following message is displayed on the browser:
Server; Error 403

What could be the reason for the message?

(a) The requested HTML file is not available
(b) The URL refers to a CGI script and the header of the script does not indicate where the interpreter is located
(c) The path to the interpreter of the script file is invalid
(d) The first line of the output from the script is not a valid HTTP header
(e) The requested HTML file or CGI script has insufficient permission.

4. Which of the following statements is incorrect regarding multimedia on the web?

(a) The MPEG, AIFF and WAV are cross-platform formats
(b) The MPEG, AU and MIDI are cross-platform formats
(c) The SND format has a relatively low fidelity
(d) VRML can be used to model and display 3D interactive graphics
(e) The dynsrc attribute in the element can be used to include videos in web pages.

5. What would be the colours of the RGB where the hexadecimal values are #FF0000, #00FF00 and #0000FF respectively?

(a) Blue, Green, Red
(b) Green, Blue, Red
(c) Green, Red, Blue
(d) Red, Blue, Green
(e) Red, Green, Blue.

6. The elements and have the following characteristics

(a) Element inherits properties defined for in a stylesheet
(b)and have no real meanings as html tags unless stylesheet is applied

(c) Elements and define content to be inline or block-level

(d)and are used as alternatives for the element
(e)is used inside element.

7. Which of the following statement is not true regarding JavaScript?

(a) JavaScript is a loosely typed language
(b) JavaScript is an object-based language
(c) JavaScript is event driven
(d) A JavaScript embedded in an HTML document is compiled and executed by the client browser
(e) JavaScript can not run in stand-alone mode (without a browser).

8. The following is a web-page:

JavaScript

When the above web page is loaded into a browser, what will happen?

(a) The body of the web page will not contain any text
(b) The body of the web page will contain the text “

hello world


(c) The body of the web page will contain the text “hello world” as an H1 heading
(d) The background color of the web page will be green
(e) document.write(”

hello world ”); is a comment.

9. The following statements are about three important browser objects in JavaScript.

I. window object : The highest of all objects in the client-side JavaScript object hierarchy.
II. navigator object : A collection of information about the browser. Useful in browser sniffing.
III. document object : Provides access to the document being viewed.
Which of the above statements is/are true?

(a) Only (I) above
(b) Only (II) above
(c) Only (III) above
(d) Both (I) and (II) above
(e) All (I), (II) and (III) above.

10. Consider the following script:

JavaScript

What will be the output of the above script?

(a) pass
(b) fail
(c) null
(d) 80
(e) Error at line 6.

Answers ::

1. D All the other options are wrong and incorrect for the question asked.

2. E All the other options are wrong and incorrect for the question asked.

3. E Server error 403 means insufficient permission.

4. A All the other options are correct for the question asked.

5. E The values are hexadecimal equivalent for Red, Green, Blue.

6. C According to the specifications of and

they are used to define
the contents inline or block level.

7. D As the remaining all the options are correct and valid for JavaScript.

8. A Because of the comment nothing will be printed.

9. E According to the definitions of browser objects, all the statements are true.

10. A Because the outcome of the ternary operator.

11. The following web page is loaded into a web server:

JavaScript question

Once the above web page is loaded what will its body contain?

(a) 2
10
(b) 1
10
(c) 110
(d) 210
(e) Error at line 7.

12. Which of the following statements is false regarding “Cookies”?

(a) Cookies are programs which run in the background of the web-client
(b) Cookies have the potential of being used to violate the privacy of users
(c) Cookies are very helpful in keeping track of users in developing online shopping cart applications, personalized portals and in advertising on web sites
(d) Cookies cannot contain more than 4Kb of data
(e) Cookies usually contain data in the form of name = value pairs.

13. Consider the following script:

JavaScript

What would be the output of the above script?

(a) 0
(b) 1
(c) 2.083
(d) 3
(e) 25%12.

14. Which of the following statements is true regarding HTTP?

(a) Web browsers use only HTTP as a communication protocol with servers
(b) It does not maintain any connection information on previous transactions
(c) It is designed to route information based on content
(d) It refers to resources using their Universal Resource Identifier (URI)
(e) It does not carry browser information to the server.

15. Which of the following is true about XHTML?

(a) It is a new hybrid technology that is different from both XML and HTML
(b) It has totally replaced HTML as the tool for building Web pages
(c) It is a reformulation of HTML in XML
(d) One cannot use it to create Web pages
(e) It has to be converted to HTML using a style sheet.

16. While working on a JavaScript project, in your JavaScript application, which function would you use to send messages to users requesting for text input?

(a) Display()
(b) Prompt()
(c) Alert()
(d) GetInput()
(e) Confirm().

17. Consider the following syntax:

When would you use the above syntax?

(a) When defining an image map
(b) When referring back to homepage.html
(c) When referring to World Map
(d) When embedding a graphic in JavaScript
(e) When aligning an image on a web page using JavaScript.

18. Which of the following is true about client-side script use in HTML documents?

(a) Java, JavaScript, Jscript and VBScript are used on many web sites as Scripting languages
(b) Client side scripts are executed on the server and the resulting page will be downloaded and interpreted by the browser
(c) Client-side scripts increase the network traffic on execution of the script
(d) Client-side scripts can perform many functions such as data validation and provide interactive feedback to the user
(e) Browsers need plug-ins to execute client-side scripts.

19. Consider the following entries in a Cascading Style Sheet (CSS) file.

P {colour: blue; background-colour: white; border-colour: red; border-left: solid}
BODY {colour: black; border-colour: green}

What is the colour of text in a paragraph of an HTML document that uses the above style sheet?

(a) green
(b) blue
(c) black
(d) red
(e) White.

20. Which property does one use to align text to the right side of a block-level element in Cascading Style Sheets?

(a) horizontal-align
(b) align
(c) block-align
(d) justify
(e) text-align.

Answers
Answer Reason
11. D Because book[1] prints 2 and book[10] prints 10

12. A Because cookies are not programs.

13. B 125/5 is 25 and 25%12 is 1(Remainder)

14. B All the other options are wrong and incorrect for the question asked.

15. C All the other options are wrong and incorrect for the question asked.

16. B Promt( ) is used to get input text from the user.

17. A All the other options are wrong and incorrect for the question asked.

18. D All the other options are wrong and incorrect for the question asked.

19. B Because for applying styles to text of a paragraph P is used in CSS. And hence the text is printed in Blue color.

20. E According to the CSS syntax for text alignment.

21. Which of the following statements is false about event handlers in JavaScript?

(a) They can be included with input tags
(b) They can be associated with end of file processing for a database application
(c) They can be included with the form tag
(d) They are generally used to call functions when triggered
(e) They can be used to trigger server-side scripts.

22. What method is used to specify a container’s layout in JSP?

(a) setLayout()
(b) Layout()
(c) setContainerLayout()
(d) ContainerLayout()
(e) setConLayout().

23. Which method of the Component class is used to set the position and size of a component in JSP?

(a) setSize()
(b) setBounds()
(c) setPosition()
(d) setPositionSize()
(e) setSizePosition().

24. What value does readLine() return when it has reached the end of a file in JSP?

(a) Last character in the file
(b) False
(c) Null
(d) EOF
(e) True.

25. Which class in JSP provides the capability to implement a growable array of objects?

(a) Array class
(b) GrowAbleArray class
(c) Container class
(d) Vector class
(e) DynamicArray class.

26. In JSP, the classes that allow primitive types to be accessed as objects are known as

(a) Primitive classes
(b) Object classes
(c) Boxing classes
(d) UnBoxing classes
(e) Wrapped classes.

27. In JSP, a Canvas object provides access to a Graphics object via one of its method called:

(a) getCanvas()
(b) getGraphics()
(c) paint()
(d) getPaint()
(e) accessGraphics().

28. In ASP the function which returns the current system date is:

(a) getDate()
(b) Date()
(c) Now()
(d) getCurrentDate()
(e) CurrentDate().

29. In ASP the function which returns an expression formatted as a date or time is:

(a) FormatDateOrTime()
(b) FormatDateAndTime()
(c) FormatTimeDate()
(d) FormatDateTime()
(e) FormatDT().

30. The function returns a Boolean value that indicates whether a specified expression can be evaluated as a number; in ASP is

(a) IsNumeric()
(b) IsNumber()
(c) IsNotNumeric()
(d) IsNotNumber()
(e) IsNumberOrNot().

Answers
Ans Reason

21. B Event handlers in JavaScript can’t be associated with end of file processing for a database application.

22. A In JSP setLayout() method is used to specify a container’s layout. The remaining all the options are incorrect.

23. B Component. setBounds() is used to set the position and size of a component in JSP.

24. C According to the semantic of the readLine() method, it returns null when it reaches the end of a file in JSP.

25. D In JSP Vector class is used implement a growable array of objects.

26. E According to the definition of the wrapper class.

27. C According to the definition of the paint() method, The remaining all the options are wrong.

28. B According to the definition of the Date() method of ASP, The remaining all the options are wrong.

29. D According to the definition of the FormatDateTime() method of ASP, The remaining all the options are wrong.

30. A In ASP, IsNumeric() function returns a Boolean value that indicates whether a specified expression can be evaluated as a number.

2 thoughts on “100 TOP WEB TECHNOLOGIES Multiple Choice Questions and Answers

Leave a Reply

Your email address will not be published. Required fields are marked *