Está en la página 1de 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

PART A (2 Marks)
(Minimum of 20 Questions in each Unit of type MCQ, True or False or open question type, no
maximum limit)
Unit I
1) What is the correct HTML tag for inserting a line break?
a. <br>
b. <lb>
c. <break>
d. <newline>
Ans : a
2) What is the correct HTML for adding a background color?
a. <body color=yellow>
b. <body bgcolor=yellow>
c. <background>yellow</background>
d. <body background=yellow>
Ans:b
3) Choose the correct HTML tag to make a text italic
a. <ii>
b. <italics>
c. <italic>
d. <i>
Ans : d
4) Choose the correct HTML tag to make a text bold?
a. <b>
b. <bold>
c. <bb>
d. <bld>
Ans: a
5) What should be the first tag in any HTML document?
a. <head>
b. <title>
c. <html>
d. <document>
Ans : c
6) Which tag allows you to add a row in a table?
a. <td> and </td>
b. <cr> and </cr>
c. <th> and </th>
d. <tr> and </tr>
Ans : d
7) How can you make a bulleted list?
a. <list>
b. <nl>
c. <ul>
d. <ol>
Ans : c
8) Which tag inserts a line horizontally on your web page?
a. <hr>
b. <line>
c. <line direction=horizontal>
Page 1 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Subject :
Technology
Sem :
VI
d. <tr>
Ans : a
9) <b> tag makes the enclosed text bold. What is other tag to make text bold?
a. <strong>
b. <dar>
c. <black>
d. <emp>
Ans : a
10) A webpage displays a picture. What tag was used to display that picture?
a. picture
b. mage
c. img
d. src
Ans: C

Web Design

11) Which is not a domain name extension


a. mil
b. org
c. .int
d. .com
Ans : C
12)using<P> tag will
a. start a new paragraph
b. break the line
c. end the current paragraph
d. none of the above
Ans : a
13)<TD> </TD> tag is used for ________
a. Table heading
b. Table Records
c. Table row
d. none of the above
Ans : b
14) Text within <STRONG> </STRONG> tag is displayed as ________
a. bold
b. italic
c. list
d. indented
Ans: a
15<UL> </UL> tag is used to ________
a. display the numbered list
b. underline the text
c. display the bulleted list
d. bold the text
Ans :c
16) What does the .com domain represents?
a. Education domain
b. Commercial domain
c. Network
d. None of the above
Ans : B
17)What is the full form of TCP/IP?
a. transmission control protocol / internet protocol
b. telephone call protocol / international protocol
Page 2 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
Sem :
c. transport control protocol / internet protocol
d. none of the above
Ans : a
18)What is the full form of HTML?
a. Hyper textmarkup language
b. Hyphenation text markup language
c. Hyphenation test marking language
d. Hyper text marking language
Ans : a
19) What is the full form of HTTP?
a. Hyper text transfer protocol
b. Hyper text transfer package
c. Hyphenation text test program
d. none of the above
Ans : a
20)Which tag creates a check box for a form in HTML?
a. <checkbox>
b. <input type=checkbox>
c. <input=checkbox>
d. <input checkbox>
Ans : b

Subject :

Web Design

VI

Unit II

21. Which of the following are the background properties in CSS?


i) background-color ii) background-image iii) background-repeat
iv) background-position v) background
A) i, ii, iii and iv only
B) i, ii, iii and v only
C) i, ii, iv and v only
D) All i, ii, iii, iv and v
Answer : D) All i, ii, iii, iv and v
22. State whether the statement is/are True.
i) font-family property is used to change the face of a font.
ii) font-variant property is used to create small-caps effects.
A) i-True, ii-False
B) i-False, ii-True
Page 3 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

C) i-True, ii-True
D) i-False, ii-False
Answer: C) i-True, ii-True
23. The CSS links properties are
A) :link, :visited, :hover, :active
B) :link, :visit, :hover, :active
C) :link, :visited, :over, :active
D) :link, :visited, :hover, :active, :inactive
Answer: . A) :link, :visited, :hover, :active
24. Internet Exploreruses .......................property to create transparent images.
A) -moz-opacity:x
B) filter: alpha(opacity=x)
C) Both of the above
D) None of the above
Answer: B) filter: alpha(opacity=x)
25. The different ways to associate styles with a HTML document is/are
A) Embedded CSS with <style> element
B) Inline CSS with style attribute.
C) External CSS with <link> element.
D) All of the above
Answer: D) All of the above

26. Which of the following is correct CSS syntex for using font property?
A) <p style="font: italic, bold, 15px;"> ................ </p>
Page 4 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

B) <p style="font-style: italic font-weight: bold font-size: 15px;"> ................... </p>


C) <p style="font: italic bold 15px;"> ....................... </p>
D) None of the above
Answer: C) <p style="font: italic bold 15px;"> ....................... </p>
27. State True of False for the CSS table properties.
i) The border-spacing specifies the width that should appear between table rows.
ii) The empty-cells specifies whether the border should be shown if a cell is empty.
A) i-True, ii-False
B) i-False, ii-True
C) i-True, ii-True
D) i-False, ii-False
Answer: B) i-False, ii-True
28. In CSS tables, the possible values for the caption-side property can have the following
values.
A) top, bottom, left or right
B) top, bottom, center, left or right
C) top or bottom
D) left or right
Answer: A) top, bottom, left or right
29. The ................... property indicates whether a cell without any content should have a
border displayed.
A) blank-cells
B) empty-cells
C) nocontent-cells
D) noborder-cells
Answer: B) empty-cells
Page 5 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

30. The ..................... specifies whether a border should be solid, dashed line, doted line,
double line, groove etc.
A) border-layout
B) border-decoration
C) border-style
D) border-weight
Answer: C) border-style
31. Which of the following are the advantages of CSS?
i) CSS saves time ii) Page load faster
iii) Easy maintenance iv) Multiple compatibility
A) i, ii and iii only
B) ii, iii and iv only
C) i, ii and iv only
D) All i, ii, iii and iv
Answer : D) All i, ii, iii and iv
32. A CSS style rule is made up of three parts which are ..
i) Selector ii) Property
iii) Value iv) Attribute
A) i, ii and iii only
B) ii, iii and iv only
C) i, ii and iv only
D) All i, ii, iii and iv
Answer : A) i, ii and iii only

33. Which is not the selector type of CSS?


A) Type selector
Page 6 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

B) Universal selector
C) Local selector
D) Descendant selector
Answer : C) Local selector
34. The correct example of class selector is .
A) h2.type1 {color: #000000;}
B) h2 type1 {color: #000000;}
C) h2 #type1 {color: #000000;}
D) #h2 type1 {color: #000000;}
Answer : A) h2.type1 {color: #000000;}
35. CSS comments are inserted inside .
A) //...................//
B) <!..................>
C) /*..................*/
D) All of the above
Answer : C) /*..................*/
36. We can handle old browsers by placing CSS codes inside.
A) //...................//
B) <!..................>
C) /*..................*/
D) None of the above
Answer : B) <!..................>
37. State whether True or False.
i) Any inline style sheet takes highest priority.
ii) Any rule defined in <style> ...........................</style> tag will override rules defined in any
external style sheet file.
Page 7 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

A) i-True, ii-False
B) i-False, ii-True
C) i-True, ii-True
D) i-False, ii-False
Answer : C) i-True, ii-True
38. ...................... is used to import an external style sheet in a manner similar to the <link>
element.
A) @insert
B) @import
C) #import
D) #insert
Answer : B) @import
39. Which of the following is / are the measurement units in CSS?
i) % ii) cm iii) em iv) pc v) px
A) i, ii, iii and iv only
B) i, ii, iii and v only
C) i, ii, iv and v only
D) All i, ii, iii, iv and v
Answer : D) All i, ii, iii, iv and v

40. The possible formats of CSS colors are.


i) Hex code - #RRGGBB
ii) Short Hex Code - #RGB
iii) RGB% - rgb(rrr%, ggg%, bbb%)
iv) Keyword - teal, blue, black
A) i, ii and iv only
Page 8 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

B) ii, iii and iv only


C) i, iii and iv only
D) All i, ii, iii and iv
Answer : D) All i, ii, iii and iv

Unit III

41. 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
42. 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
43. ______ JavaScript is also called client-side JavaScript.
A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: B
44. __________ JavaScript is also called server-side JavaScript.
A. Microsoft
B. Navigator
C. LiveWire
D. Native
Ans: C
45. 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
Page 9 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

46. _____ 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
47. 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
48. 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
49. 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
50. 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
51. ______ tag is an extension to HTML that can enclose any number of JavaScript
statements.
A. <SCRIPT>
B. <BODY>
C. <HEAD>
D. <TITLE>
Ans: A
52. 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
Page 10 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

Ans: A
53. Which of the following attribute can hold the JavaScript version?
A. LANGUAGE
B. SCRIPT
C. VERSION
D. None of the above
Ans: A
54. 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
55. 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
56. Inside which HTML element do we put the JavaScript?
A. <js>
B. <scripting>
C. <script>
D. <javascript>
Ans: C
57. 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
58. 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
59. 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
Page 11 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

60. 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
.
Unit IV

61. 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
62. 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
63. JavaScript entities start with _______ and end with _________.
A. Semicolon, colon
B. Semicolon, Ampersand
C. Ampersand, colon
D. Ampersand, semicolon
Ans: D
64. 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
65. Choose the server-side JavaScript object?
A. FileUpLoad
B. Function
C. File
D. Date
Ans: C
66. Choose the client-side JavaScript object?
Page 12 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

A. Database
B. Cursor
C. Client
D. FileUpLoad
Ans: D
67. Which of the following is not considered a JavaScript operator?
A. new
B. this
C. delete
D. typeof
Ans: B
68. ______method evaluates a string of JavaScript code in the context of the specified
object.
A. Eval
B. ParseInt
C. ParseFloat
D. Efloat
Ans: A
69. 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
70. The syntax of Eval is ________________
A. [objectName.]eval(numeriC.
B. [objectName.]eval(string)
C. [EvalName.]eval(string)
D. [EvalName.]eval(numeriC.
Ans: B
71. JavaScript is interpreted by _________
A. Client
B. Server
C. Object
D. None of the above
Ans: A
72. Using _______ statement is how you test for a specific condition.
A. Select
B. If
C. Switch
D. For
Ans: B
Page 13 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

73. 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
74. 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
75. The _______ method of an Array object adds and/or removes elements from an array.
A. Reverse
B. Shift
C. Slice
D. Splice
Ans: D
76. 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

77. Which tag(s) can handle mouse events in Netscape?


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

Page 14 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

79. 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
80. 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
.
Unit V

81. What does XML stand for?


A. eXtra Modern Link
B. eXtensibleMarkup Language
C. Example Markup Language
D. X-Markup Language
Ans: B
82. 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
83. 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
84. Is it easier to process XML than HTML?
A. Yes
B. No
C. Somtimes
D. Cant say
Ans: A
Page 15 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

85. 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
86. Kind of Parsers are
A. well-formed
B. well-documented
C. non-validating and validating
D. none of the above
Ans: C
87. 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
88. Comment in XML document is given by
A. <?-- -->
B. <!-- --!>
C. <!-- -->
D. </-- -- >
Ans: C
89. 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
90. Which of the following strings are a correct XML name?
A. _myElement
B. my Element
C. #myElement
D. None of the above
Ans: A
Page 16 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

91. Which of the following strings are a correct XML name?


A. xmlExtension
B. xslNewElement
C. XMLElement#123
D. All
Ans: B
92. 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
93. What are the predefined attributes
A. xml:lang
B. xml:space
C. both
D. none.
Ans: C
94. Kind of Parsers are
A. well-formed
B. validating
C. non-validating
D. Both B & C
Ans: D
95. 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
96. XML uses the features of
A. HTML
B. XHTML
C. VML
D. SGML
Ans: D
97. XML document can be viewed in
Page 17 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

A. IE C.0
B. IE B.0
C. IE 6.0
D. IE X.0
Ans: C
98. 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
99. What does DTD stand for?
A. Direct Type Definition
B. Document Type Definition
C. Do The Dance
D. Dynamic Type Definition
Ans: B
100. 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

PART B (5 Marks)
(Minimum 10 Question from Each unit, no maximum limit)
Unit I
1.Write a Basic Program in HTML
Answer
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
Page 18 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>

Subject :
Sem :

Web Design

VI

</body>
</html>
2.Write a program using HTML Attributes
Answer
<!DOCTYPE html>
<html>
<body>
<h1>About W3Schools</h1>
<p title="About W3Schools">
W3Schools is a web developer's site.
It provides tutorials and references covering
many aspects of web programming,
including HTML, CSS, JavaScript, XML, SQL, PHP, ASP, etc.
</p>
<p><b>
If you move the mouse over the paragraph above,
the title will display as a tooltip.
</b></p>
</body>
</html>
the<p> element has a title attribute. The value of the attribute is "About
W3Schools":

3.Write a program using <ahref> attribute


Answer
<!DOCTYPE html>
<html>
<body>
<a href="http://www.w3schools.com">This is a link</a>
</body>
</html>
4.Write a program using image attribute
Answer
<!DOCTYPE html>
<html>
<body>
<imgsrc="w3schools.jpg" alt="W3Schools.com" width="104" height="142">
Page 19 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

</body>
</html>
5.Write a program using HTML-TextAlign attribute
Answer
<!DOCTYPE html>
<html>
<body>
<h1 style="text-align:center">Centered heading</h1>
<p>This is a paragraph.</p>
</body>
</html>
6.Write a program using HTML-Font attribute
<!DOCTYPE html>
<html>
<body>
<h1 style="font-family:verdana">This is a heading</h1>
<p style="font-family:courier">This is a paragraph.</p>
</body>
</html>

7.Write a program using HTML-Fontcolorattribute


Answer
<!DOCTYPE html>
<html>
<body>
<h1 style="color:blue">This is a heading</h1>
<p style="color:red">This is a paragraph.</p>
</body>
</html>
8.Write a program using HTML-Fontformatting attribute
Answer
<!DOCTYPE html>
<html>
<body>
<p>This text is normal.</p>
Page 20 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Subject :
Technology
Sem :
VI
<p><b>This text is bold.</b></p>
<p><strong>This text is strong.</strong></p>
<p><i>This text is italic.</i></p>
<p><em>This text is emphasized.</em></p>
<h2>HTML <small>Small</small> Formatting</h2>

Web Design

</body>
</html>
9.Write a program using HTML-Links attribute
Answer
<!DOCTYPE html>
<html>
<body>
<p><a href="http://www.w3schools.com/html/">Visit our HTML
tutorial</a></p>
</body>
</html>
10.Write a program using HTML-Un-Ordered List attribute
Answer
<!DOCTYPE html>
<html>
<body>
<h2>Unordered List with Circle Bullets</h2>
<ul style="list-style-type:circle">
<li>Coffee</li>
<li>Tea</li>
<li>Milk</li>
</ul>
</body>
</html>

.
Unit II
11.Write a CSS program id selector
Answer:
<!DOCTYPE html>
<html>
<head>
<style>
Page 21 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
#para1 {
text-align: center;
color: red;
}
</style>
</head>
<body>

Subject :
Sem :

Web Design

VI

<p id="para1">Hello World!</p>


<p>This paragraph is not affected by the style.</p>
</body>
</html>
Output

Hello World!
This paragraph is not affected by the style.

12.Write a program for The class selector (for only <p> elements)
Answer:
<!DOCTYPE html>
<html>
<head>
<style>
text-align: center;
p.center {
color: red;
}
</style>
</head>
<body>
<h1 class="center">This heading will not be affected</h1>
<p class="center">This paragraph will be red and center-aligned.</p>
</body>
</html>
Output

This heading will not be affected


This paragraph will be red and center-aligned.
Page 22 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

13.write a program for css to set the color of the borders


Answer:
<!DOCTYPE html>
<html>
<head>
<style>
p.one {
border-style: solid;
border-color: #0000ff;
}
p.two {
border-style: solid;
border-color: #ff0000 #0000ff;
}
p.three {
border-style: solid;
border-color: #ff0000 #00ff00 #0000ff;
}
p.four {
border-style: solid;
border-color: #ff0000 #00ff00 #0000ff rgb(250,0,255);
}
</style>
</head>
<body>
<p class="one">One-colored border!</p>
<p class="two">Two-colored border!</p>
<p class="three">Three-colored border!</p>
<p class="four">Four-colored border!</p>
<p><b>Note:</b> The "border-color" property does not work if it is used alone. Use the "borderstyle" property to set the borders first.</p>
</body>
</html>
14. Write a program for CSS vertical alignment of an image
Answer:
<!DOCTYPE html>
<html>
<head>
<style>
Page 23 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
img.top {
vertical-align: text-top;
}

Subject :
Sem :

Web Design

VI

img.bottom {
vertical-align: text-bottom;
}
</style>
</head>
<body>
<p>An <imgsrc="w3schools_logo.gif" alt="W3Schools" width="270" height="50"> image with a
default alignment.</p><br>
<p>An <img class="top" src="w3schools_logo.gif" alt="W3Schools" width="270" height="50">
image with a text-top alignment.</p><br>
<p>An <img class="bottom" src="w3schools_logo.gif" alt="W3Schools" width="270" height="50">
image with a text-bottom alignment.</p>
</body>
</html>
15. list the css background properties
Answer:
List the type and descriptions(tables).
16. Explain the concepts of CSS border properties
Answer:
List the type and descriptions(tables).
17. Explain the concepts of CSS padding properties
Answer:
List the type and descriptions(tables).
18. Explain the concept of CSS Text Alignment.
Answer:
Definition and example program.
19. write a program to Set the text color in CSS.
Answer:
<!DOCTYPE html>
<html>
<head>
<style>
body {
Page 24 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
color: blue;
}

Subject :
Sem :

Web Design

VI

h1 {
color: green;
}
</style>
</head>
<body>
<h1>This is heading 1</h1>
<p>This is an ordinary paragraph. Notice that this text is blue. The default text color for a page is
defined in the body selector.</p>
</body>
</html>
20.Write a program to All the font properties in one declaration
Answer:
<!DOCTYPE html>
<html>
<head>
<style>
p.ex1 {
font: 15px arial, sans-serif;
}
p.ex2 {
font:italic bold 12px/30px Georgia, serif;
}
</style>
</head>
<body>
<p class="ex1">This is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph. This
is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph.</p>
<p class="ex2">This is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph. This
is a paragraph. This is a paragraph. This is a paragraph. This is a paragraph.</p>
</body>
</html>

Unit III
21. write a basic program of Javascript
Answer:
Page 25 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
<!DOCTYPE html>
<html>
<body>

Subject :
Sem :

Web Design

VI

<h1>What Can JavaScript Do?</h1>


<p id="demo">JavaScript can change HTML content.</p>
<button type="button"
onclick="document.getElementById('demo').innerHTML = 'Hello JavaScript!'">
Click Me!</button>
</body>
</html>
22. Explain the concept of If and If-else Statements
Answer:
Explanation and syntax
23. Explain the concept of while and do-while Statements
Answer:
Explanation and syntax
24. Explain the concept of Assignment operators in Javascript
Answer:
Explanation and syntax
25.List the Javascript comparision and logical operators
Answer:
Explanation and syntax
26. Write a javascript program using function object.
Answer:
<!DOCTYPE html>
<html>
<body>
<p>Accessing a function without (), will return the function definition:</p>
<p id="demo"></p>
<script>
function toCelsius(f) {
return (5/9) * (f-32);
}
document.getElementById("demo").innerHTML = toCelsius;
</script>
</body>
</html>
Page 26 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

27. Write short note on Java script statements.


Answer:
Explanation with example programs
28. Write short note on Java script variables.
Answer:
Explanation with example programs

29. Write short note on Java script datatypes


Answer:
Explanation with example programs
30. Write short note on Java script strings
Answer:
Explanation with example programs

.Unit IV
31. Write short note on Arrays
Answer:
Explanation with example programs
32. Write a short note on Associative Arrays
Answer:
Explanation with example programs
.
33. Write a short note Sorting an Array
Answer:
Explanation with example programs
34. Explain the Concept of Math Object
Answer
Explanation with syntax and its types
35. Explain the Concept of String Object
Answer
Explanation with syntax and its types and properties list
36. Explain the Concept of Date Object
Answer
Explanation with syntax and its types and properties list
.
37. Explain the Concept of Boolean Object
Answer
Explanation with syntax and its types and properties list
38. Explain the Concept of Number Object
Page 27 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Subject :
Technology
Sem :
VI
Answer
Explanation with syntax and its types and properties list

Web Design

39. Explain the Concept of Window Object


Answer
Explanation with syntax and its types and properties list
40. Write a short note Reversing an Array
Answer:
Explanation with example programs
Unit V
41.write a concepts of onClick event
Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body>
<button onclick="this.innerHTML=Date()">The time is?</button>
</body>
</html>
42. write a concepts of onload event
Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body onload="myFunction()">
<h1>Hello World!</h1>
<script>
function myFunction() {
alert("Page is loaded");
}
</script>
</body>
</html>

43. write a concepts of onmousemove event


Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<head>
Page 28 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
<style>
div {
width: 200px;
height: 100px;
border: 1px solid black;
}
</style>
</head>
<body>

Subject :
Sem :

Web Design

VI

<div onmousemove="myFunction(event)" onmouseout="clearCoor()"></div>


<p>Mouse over the rectangle above, and get the coordinates of your mouse pointer.</p>
<p>When the mouse is moved over the div, the p element will display the horizontal and vertical
coordinates of your mouse pointer, whose values are returned from the clientX and clientY properties
on the
MouseEvent object.</p>
<p id="demo"></p>
<script>
function myFunction(e) {
var x = e.clientX;
var y = e.clientY;
var coor = "Coordinates: (" + x + "," + y + ")";
document.getElementById("demo").innerHTML = coor;
}
function clearCoor() {
document.getElementById("demo").innerHTML = "";
}
</script>
</body>
</html>

44. write a concepts of onmouseover event


Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body>
<img onmouseover="bigImg(this)" onmouseout="normalImg(this)" border="0" src="smiley.gif"
alt="Smiley" width="32" height="32">
<p>The function bigImg() is triggered when the user moves the mouse pointer over the image.</p>
<p>The function normalImg() is triggered when the mouse pointer is moved out of the image.</p>
<script>
function bigImg(x) {
Page 29 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
x.style.height = "64px";
x.style.width = "64px";
}

Subject :
Sem :

Web Design

VI

function normalImg(x) {
x.style.height = "32px";
x.style.width = "32px";
}
</script>
</body>
</html>

45. write a concepts of onmouseout event


Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body>
<img onmouseover="bigImg(this)" onmouseout="normalImg(this)" border="0" src="smiley.gif"
alt="Smiley" width="32" height="32">
<p>The function bigImg() is triggered when the user moves the mouse pointer over the image.</p>
<p>The function normalImg() is triggered when the mouse pointer is moved out of the image.</p>
<script>
function bigImg(x) {
x.style.height = "64px";
x.style.width = "64px";
}
function normalImg(x) {
x.style.height = "32px";
x.style.width = "32px";
}
</script>
</body>
</html>

46. write a concepts of onFocus event


Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body>
Enter your name: <input type="text" onfocus="myFunction(this)">
Page 30 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<p>When the input field gets focus, a function is triggered which changes the background-color.</p>
<script>
function myFunction(x) {
x.style.background = "yellow";
}
</script>
</body>
</html>

47. . write a concepts of onblur event


Answer:
Explanations. And program
<!DOCTYPE html>
<html>
<body>
Enter your name: <input type="text" id="fname" onblur="myFunction()">
<p>When you leave the input field, a function is triggered which transforms the input text to upper
case.</p>
<script>
function myFunction() {
var x = document.getElementById("fname");
x.value = x.value.toUpperCase();
}
</script>
</body>
</html>
.
48 . . write a concepts of onsubmit event
Answer:
Explanations With syntax.
<!DOCTYPE html>
<html>
<body>
<p>When you submit the form, a function is triggered which alerts some text.</p>
<form action="demo_form.asp" onsubmit="myFunction()">
Enter name: <input type="text" name="fname">
<input type="submit" value="Submit">
</form>
<script>
function myFunction() {
Page 31 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
alert("The form was submitted");
}
</script>
</body>
</html>

Subject :
Sem :

Web Design

VI

49. write a concepts of onreset event


Answer:
<!DOCTYPE html>
<html>
<body>
<p>When you reset the form, a function is triggered which alerts some text.</p>
<form onreset="myFunction()">
Enter name: <input type="text">
<input type="reset">
</form>
<script>
function myFunction() {
alert("The form was reset");
}
</script>
</body>
</html>

50. Write a program to Display the date and time the document was last modified.
Answer
<!DOCTYPE html>
<html>
<body>
<p>This document was last modified <span id="demo"></span>.</p>
<script>
document.getElementById("demo").innerHTML = document.lastModified;
</script>
</body>
</html>

Page 32 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

PART C (10 Marks)


(Minimum 5 Questions from Each unit, no maximum limit)
Unit I
1. Explain the concepts of ordered list and unordered list of html in detail
Answer:Explanations and programs.
2. Explain the concepts of Html tables with program..
Answer: Explanations and programs.
3. Explain the concepts of links with text and images of html with example program
Answer: Explanations and programs.
4. Explain the concept of frames of html in Detail
Answer: Explanations and programs
5. Explain the concept of forms of html in Detail
Answer: Explanations and programs

Unit II
6. Explain the concept of CSS borders briefly with example program
Answer:
border-color,border-style,Border Width,border-top-color
7. Explain the concepts of CSS text briefly with example programs
Answer:
Text colour , text alignment , text decoration,Text Transformation
8.

Explain the concepts of CSS Lists with example program


Page 33 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
Answer:
Explanations and programs.

Subject :
Sem :

Web Design

VI

9. Explain the concepts of CSS tableswith example program


Answer:
Explanations and programs.
10. Explain the concepts of CSS linkswith example program
Answer:
Explanations and programs.
.
Unit III

1. Explain the concept of control structures in javascript (IF,If-Else,While and Do-While)


Answer
Explanation with example programs

2. Explain the concept of Arithmetic and logical operators in detail


Answer
Explanation with example programs

3. Explain the concept of javascript statements and Variables in detail


Answer
Explanation with example programs

4. Write a Javascript program using Arrays


Answer
<!DOCTYPE html>
<html>
<body>
<p id="demo"></p>
<script>
var cars = ["Saab", "Volvo", "BMW"];
document.getElementById("demo").innerHTML = cars[0];
</script>
Page 34 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
</body>
</html>

Subject :
Sem :

Web Design

VI

5. Write a javascript program


Answer
<!DOCTYPE html>
<html>
<body>
<h1>What Can JavaScript Do?</h1>
<p id="demo">JavaScript can change HTML content.</p>
<button type="button"
onclick="document.getElementById('demo').innerHTML = 'Hello JavaScript!'">
Click Me!</button>
</body>
</html>

Unit- IV

1. Explain the concept of javascript Functions


Answer
Explanation with example programs
<!DOCTYPE html>
<html>
<body>
<p>This example calls a function which performs a calculation, and returns the result:</p>
<p id="demo"></p>
<script>
function myFunction(a, b) {
return a * b;
}
document.getElementById("demo").innerHTML = myFunction(4, 3);
</script>
</body>
</html>
Page 35 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

2. Explain the concept of Math and date object in detail


Answer
The Math object allows you to perform mathematical tasks.
Math is not a constructor. All properties/methods of Math can be called by using Math as an object,
without creating it.
Syntax
var x = Math.PI;
// Returns PI
var y = Math.sqrt(16);
// Returns the square root of 16

MATH OBJECT
<!DOCTYPE html>
<html>
<body>
<h1>JavaScript Math.round()</h1>
<p>Math.round(x) returns the value of x rounded down to its nearest integer:</p>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = Math.round(4.4);
</script>
</body> </html>
DATE Object
The Date object is used to work with dates and times.
Date objects are created with new Date().
There are four ways of instantiating a date:
var d = new Date();
var d = new Date(milliseconds);
var d = new Date(dateString);
var d = new Date(year, month, day, hours, minutes, seconds, milliseconds);

<!DOCTYPE html>
Page 36 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<html>
<body>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = Date();
</script>
</body>
</html>
3. Explain the concept of Boolean and Number object in detail
Answer
BOOLEAN
JavaScript booleans can have one of two values: true or false.
The Boolean() Function
You can use the Boolean() function to find out if an expression is true:
Example
Boolean(10 > 9)
Try it Yourself
Or even easier:

// returns true

Example
(10 > 9)
10 > 9

// also returns true


// also returns true

Program
<!DOCTYPE html>
<html>
<body>
<p>Display the value of Boolean(10 > 9):</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
document.getElementById("demo").innerHTML = Boolean(10 > 9);
Page 37 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology
}
</script>

Subject :
Sem :

Web Design

VI

</body>
</html>
NUMBER OBJECT
JavaScript has only one type of number.
Numbers can be written with, or without, decimals:
Example
var x = 3.14; // A number with decimals
var y = 34;
// A number without decimals
Extra large or extra small numbers can be written with scientific (exponent) notation:
Example
var x = 123e5; // 12300000
var y = 123e-5; // 0.00123
Program
<!DOCTYPE html>
<html>
<body>
<p>Floating point arithmetic is not always 100% accurate.</p>
<p>But it helps to multiply and divide.</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
var x = (0.2*10 + 0.1*10) / 10;
document.getElementById("demo").innerHTML = "0.2 + 0.1 = " + x;
}
</script>
</body>
</html>

Explanation with example programs


4. Explain the concept of Sorting and reversing an Array in detail
Answer
SORTING
Page 38 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<!DOCTYPE html>
<html>
<body>
<p>The sort() method sorts an array alphabetically.</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
var fruits = ["Banana", "Orange", "Apple", "Mango"];
document.getElementById("demo").innerHTML = fruits;
function myFunction() {
fruits.sort();
document.getElementById("demo").innerHTML = fruits;
}
</script>
</body>
</html>
Reversing an Array
The reverse() method reverses the elements in an array.
You can use it to sort an array in descending order:
Example
<!DOCTYPE html>
<html>
<body>
<p>The sort() method sorts an array alphabetically.</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
var fruits = ["Banana", "Orange", "Apple", "Mango"];
document.getElementById("demo").innerHTML = fruits;
Page 39 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Subject :
Technology
Sem :
VI
function myFunction() {
fruits.sort();
fruits.reverse();
document.getElementById("demo").innerHTML = fruits;
}
</script>

Web Design

</body>
</html>

Explanation with example programs


5. Explain the concept of String and Window object in detail
Answer
Explanation with example programs

Unit V

1. Explain the concept of onClick and Onload Event


Answer
On Click
<!DOCTYPE html>
<html>
<body>
<button onclick="document.getElementById('demo').innerHTML=Date()">The time is?
</button>
<p id="demo"></p>
</body>
</html>
OnLoad
<!DOCTYPE html>
<html>
<head>
<script>
Page 40 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

function myFunction() {
alert("Page is loaded");
}
</script>
</head>
<body onload="myFunction()">
<h1>Hello World!</h1>
</body>
</html>
2. Explain the concept of OnMousemove and OnMouseover event in detail
Answer
<!DOCTYPE html>
<html>
<head>
<script>
function myFunction(e) {
x = e.clientX;
y = e.clientY;
coor = "Coordinates: (" + x + "," + y + ")";
document.getElementById("demo").innerHTML = coor
}
function clearCoor() {
document.getElementById("demo").innerHTML = "";
}
</script>
</head>
<body style="margin:0px;">
Page 41 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<div id="coordiv" style="width:199px;height:99px;border:1px solid"


onmousemove="myFunction(event)" onmouseout="clearCoor()"></div>

<p>Mouse over the rectangle above, and get the coordinates of your mouse pointer.</p>
<p id="demo"></p>
</body>
</html>
3. Explain the concept OnMouseout and OnFocus event in detail
Answer
<!DOCTYPE html>
<html>
<body>
<h1 onmouseover="style.color='red'" onmouseout="style.color='black'">Mouse over this
text</h1>
</body>
</html>
OnFocus
<!DOCTYPE html>
<html>
<head>
<script>
function myFunction(x) {
x.style.background = "yellow";
}
</script>
</head>
<body>
Enter your name: <input type="text" onfocus="myFunction(this)">
Page 42 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<p>When the input field gets focus, a function is triggered which changes the backgroundcolor.</p>

</body>
</html>
4. Explain the concept Onblur and OnSubmit event in detail
Answer
OnBlur
<!DOCTYPE html>
<html>
<head>
<script>
function myFunction() {
var x = document.getElementById("fname");
x.value = x.value.toUpperCase();
}
</script>
</head>
<body>
Enter your name: <input type="text" id="fname" onblur="myFunction()">
<p>When you leave the input field, a function is triggered which transforms the input text to
upper case.</p>
</body>
</html>
OnSubmit
<!DOCTYPE html>
<html>
<head>
Page 43 of 44

RATHINAM COLLEGE OF ARTS AND SCIENCE (AUTONOMOUS)

Question Bank

Class :
III BCOM (CA) A&B
Technology

Subject :
Sem :

Web Design

VI

<script>
function confirmInput() {
fname = document.forms[0].fname.value;
alert("Hello " + fname + "! You will now be redirected to www.w3Schools.com");
}
</script>
</head>
<body>
<form onsubmit="confirmInput()" action="http://www.w3schools.com/">
Enter your name: <input id="fname" type="text" size="20">
<input type="submit">
</form>
</body>
</html>
5. Explain all the event handlers and its properties in detail.
Answer
Explanation

Page 44 of 44