wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

quiz based on web design

Total questions: 40

Worksheet time: 23mins

Name
Class
Date
1.

If you want to align text to the right side of an block element in a cascading style sheet (CSS) then which of the following property would you use?

a)

Right align

b)

Justify

c)

Left align

d)

Text align

2.

In a Javascript Application what function can be used to send messages to users requesting for an text input?

a)

Display()

b)

Alert()

c)

GetOutput()

d)

Prompt()

3.

Assume that an HTML form is designed to purchase the furniture. All the items required are being checked. After selecting the items the payment details are entered and the submit button is pressed. From the following options which one would you prefer to send the data to the server. Assume that all the security is handled.

a)

Only POST

b)

Only GET

c)

Either of GET or POST

d)

Neither GET nor POST

4.

Which of the following attributes of text box control allow to limit the maximum character?

a)

size

b)

len

c)

maxlength

d)

Both a and c

5.

Which of the following is a container?

a)

<SELECT>

b)

<BODY>

c)

<INPUT>

d)

Both (a) and (b)

6.

<DT> tag is designed to fit a single line of our web page but <DD> tag will accept a

a)

line of text

b)

full paragraph

c)

word

d)

request

7.

From which tag the descriptive list starts?

a)

<DT>

b)

<DD>

c)

<DL>

d)

<DS>

8.

Choose the correct option.

a)

<th> is used for defining the heading of a table.

b)

By default, contents written between <th> and </th> are bold and centered.

c)

Both A and B

d)

None of the above

9.

Fill in the blanks with the help of options given below in order to get the following table when the below code is executed.

a)

colspan= "1"

b)

colspan= "2"

c)

rowspan= "1"

d)

rowspan= "2"

10.

In order to add space of 20px between cell content and its border of a table in html, which one of the following option is appropriate?

a)

th,td{ padding: 20px;}

b)

table{ margin:20px; }

c)

table{ border : 20px;}

d)

table{ padding: 20px; }

11.

Fill in the blanks with the help of options given below in order to get the following table when the below code is executed.

a)

colspan= "1"

b)

colspan= "2"

c)

rowspan= "1"

d)

rowspan= "2"

12.

In HTML tables space between cell content and cell border is called

a)

Cell spacing

b)

Cell difference

c)

Cell padding

d)

All of above

13.

Headings of table lies inside ___________

a)

<thead>

b)

<tfoot>

c)

<th>

d)

<tbody>

14.

Fill in the blanks in the above HTML code with a suitable option so as to get the list as follows when executed in a browser.

a)

style="list-style-type:square;"

b)

style="list-type:square;"

c)

style="type:square;"

d)

style= "style:square;"

15.

Fill in the blanks with a suitable option in order to number items of an ordered list with small roman numbers.

a)

style= "type:i"

b)

style= "list-style-type:i"

c)

type= "i"

d)

type= "small roman"

16.

A HTML code is given below

Fill in the blanks with appropriate option to get the output as below:

a)

<dd>,</dd>,<dt>,</dt>

b)

<dt>,</dt>,<dd>,</dd>

c)

<li>,</li>,<dd>,</dd>

d)

<dt>,</dt>,<li>,</li>

17.

What is the default item marker in unordered lists of HTML?

a)

Circle

b)

Marker

c)

disc

d)

None of the above

18.

Which of the following is a new input attribute introduce by HTML5?

a)

text

b)

checkbox controls

c)

submit buttons

d)

date

19.

Which element is used to create multi-line text input?

a)

text

b)

textarea

c)

submit

d)

radio button

20.

Which attribute is not used for the radio type?

a)

name

b)

value

c)

checked

d)

selected

21.

Choose the correct option.

a)

Use of method attribute determines by which method the datas in the form will be submitted.

b)

Method can be POST or GET.

c)

Default method in HTML is GET.

d)

All of the above

22.

How more than one option can be selected in drop down?

a)

Use of multiple attribute inside <option> tag.

b)

Use of multiple attribute inside <select> tag.

c)

use of multiple attribute inside <text> tag.

d)

It is not possible to select more than one option in drop down.

23.

when form data contains sensitive and personal information the which method is more preferable.

a)

GET method

b)

POST method

c)

Host method

d)

Put methods

24.

The ______ tag defines an image in an HTML page.

a)

<pic>

b)

<image>

c)

<imge>

d)

<img>

25.

Pseudo-classes In CSS

a)

Match A Specified Element

b)

Select The Active Links

c)

Are Used To Select All The Visited Links

d)

Are Used To Define A Special State Of An Element

26.

What Should Be The Table Width, So That The Width Of A Table Adjust To The Current Width Of The Browser Window?

a)

640 Pixels

b)

100.00%

c)

Full-screen

d)

1024 Px

27.

Which Of The Following Selector Selects All Elements Of E That Have The Attribute Attr That End With The Given Value?

a)

E[attr^=value]

b)

E[attr$=value]

c)

E[attr*=value]

d)

None Of The Mentioned

28.

Which Of The Following Selector Selects The Elements That Are Checked?

a)

E ~ F

b)

::after

c)

:checked

d)

None Of The Mentioned

29.

Which CSS Property Sets The Stack Order Of An Element?

a)

Z-index

b)

Position

c)

Overflow

d)

Clip

30.

Given the HTML below, how would you select it by id?

< p id="dorothea" >Perhaps we don't always discriminate between sense and nonsense.< /p >

a)

dorothea

b)

#dorothea

c)

.dorothea

d)

None of the given.

31.

Examine the HTML and accompanying CSS below.


< p id="opening-paragraph" class="dorothea" >Miss Brooke had that kind of beauty which seems to be thrown into relief by poor dress.< /p >


#opening-paragraph { color: blue; }

.dorothea { color: red; }


With which color will the paragraph appear on the page?

a)

green

b)

blue

c)

red

d)

black (the default)

32.

< ul id="forest" >

< li class="evergreen" >< a >pine< /a >< /li >

< li class="evergreen" >< a >lodgepole< /a >< /li >

< li class="evergreen fruit" >< a >holly< /a >< /li >

< li class="leaf fruit" >< a >apple< /a >< /li >

< li class="leaf" >< a >oak< /a >< /li >

< li class="leaf" >< a >maple< /a >< /li>

< /ul >

There may be other lists on the page, in addition to the one above. Given that, what selector would you use to select all the list items in the forest's unordered list?

a)

ul li

b)

#forest li

c)

ul>li

d)

li

33.

.important {

color:red;

}

In CSS, when we use a selector like .important, it means that:

a)

important is not correct, there is no such selector in CSS

b)

We are going to select all HTML elements that have a class="important" attribute/value, and the CSS rule will be applied to all these elements

c)

We are going to select a single HTML element that has the id="important" attribute. Two HTML elements cannot have the same value for the id attribute (it must be unique and it acts as an identifier)

d)

None of the given.

34.

< p id="physics" class="rainbow" >Rainbows result from refraction of sunlight in falling water droplets plus reflection of the light from the back of the droplet.< /p >


p { color: blue; }

html, body { color: black; }


With which color will the paragraph appear?

a)

black

b)

blue

c)

red

d)

green

35.

The property that applies an underline does not accept which of the value below?

a)

underline

b)

overline

c)

line-through

d)

italic

36.

What will be the output of the following JavaScript statement?

var grand_Total=eval("10*10+5");

a)

10*10+5

b)

105 as a string

c)

105 as an integer value

d)

Exception is thrown

37.

Will the following JavaScript code work?

var tensquared = (function(x) {return x*x;}(10));

a)

Yes, perfectly

b)

Error

c)

Exception will be thrown

d)

Memory leak

38.

What will be the output of the following JavaScript code?

var string2Num=parseInt("123xyz");

a)

123

b)

123xyz

c)

Exception

d)

NaN

39.

what will be the result of this code

<html>

<body>

<script>

var fruit = 'apple'


{

var fruit = 'orange'

document.write(fruit+"<br>")

}


document.write(fruit)

</script>

</body>

</html>

a)

orange

orange

b)

orange

apple

c)

apple

apple

d)

apple

orange

40.

what will be the output of the following code

<html>

<body>

<script>

let fruit = 'apple'

{

let fruit = 'orange'

document.write(fruit+"<br>")

}

document.write(fruit)

</script>

</body>

</html>

a)

orange

orange

b)

apple

apple

c)

orange

apple

d)

apple

orange