You are on page 1of 3

W1-2-60-1-6

JOMO KENYATTA UNIVERSITY OF AGRICULTURE AND TECHNOLOGY

UNIVERSITY EXAMINATIONS 2016/2017


FIRST YEAR SECOND SEMESTER UNIVERSITY EXAMINATION FOR THE DIPLOMA
IN INFORMATION TECHNOLOGY

DIT 0302: WEB DEVELOPMENT I

DATE: AUGUST, 2017 TIME: 1 ½ HOURS

INSTRUCTIONS: ANSWER ALL QUESTIONS IN SECTION A (COMPULSORY) AND


ANY OTHER TWO QUESTIONS IN SECTION B

QUESTION ONE: 40 MARKS

a. Define CSS. (2 marks)

b. What is the function of a CSS vendor prefix? Write down at least four
vendor prefixes for some of the popular web browsers. (6 marks)

c. What are HTML attributes? Give an example. (4 marks)

d. Describe at least four formatting elements in HTML. (4 marks)

e. Write down the syntax for the inclusion of HTML entities in a HTML
document. (2 marks)

f. Define SVG. (2 marks)

g. What are the valid scopes of a variable in java script? (4 marks)

h. What is the difference between an anonymous function and a named


function? (4 marks)

i. How are cookies created in java script? (4 marks)

j. State the purpose of the following tags in HTML5. (8 marks)

1
i. Section

ii. Article

iii. Figure

iv. Nav

v. Dialog

vi. Aside

vii. Header

viii. Canvas

SECTION B

QUESTION TWO

a. What is a universal selector? (2 marks)

b. What is a descendant selector? Give an example. (3 marks)

c. Use example to differentiate between a child selector and an attribute


selector. (6 marks)

d. Differentiate em, Vh, ex and px units of measurement as used in CSS.


(4 marks)

QUESTION THREE

a. What are the drawbacks of cookies? (3 marks)

b. What are Pseudo-classes? (2 marks)

c. Describe four Pseudo-classes that can be used on the link tag. Give an
example for each case. (8 marks)

2
QUESTION FOUR

a. How are arrays created in java script? (2 marks)

b. How are array elements read in java script? (3 marks)

c. Show how to redirect a UN in java script. (2 mark)

d. Ste at least five functions of Java script on a webage. (5 marks)

e. List down three values that are treated as FALSE in java script. (3 marks)

QUESTION FIVE

a. What does HTML DOM define? (3 marks)

b. Using a code snippet, show how to change the background colours of divs
with the class name square to blue. (5 marks)

c. Identify four navigation pointers of a DOM tree. (4 marks)

d. How are exceptions handled in Java script. (3 marks)

You might also like