Information Technology · June 2022 · Question paper · Unit 2

Edexcel IAL Information Technology question paper for Unit 2, June 2022, file IAL_IT_2022_MayJune_U2_QP.pdf.

Advertisement
Loading the paper…
Text of this paper

Please check the examination details below before entering your candidate information
Candidate surname

Centre Number

Other names

Candidate Number

Pearson Edexcel International Advanced Level
Time 3 hours

Paper
reference

Information Technology

WIT12/01
 

International Advanced Subsidiary / Advanced Level

UNIT 2

You must have:
A computer workstation with a text editor, browser software and
Questions folder (containing assets, HTML and CSS files).

Total Marks

Instructions

black ink or ball-point pen.
• Use
Fill
in
boxes at the top of this page with your name,
• centrethe
number and candidate number.
all questions.
• Answer
the questions requiring a written answer in the spaces provided
• Answer
– there may be more space than you need.
out the practical tasks on the computer workstation and save new or
• Carry
amended files using the file name given in the question.
• You must not use the internet during the examination.

Information

total mark for this paper is 80.
• The
marks for each question are shown in brackets
• The
– use this as a guide as to how much time to spend on each question.

Advice

each question carefully before you start to answer it.
• Read
to answer every question.
• Try
your work regularly.
• Save
Check
• your answers if you have time at the end.
Turn over

P71386A
©2022 Pearson Education Ltd.

Q:1/1/1/1/

*P71386A0120*

SECTION A
You are advised to spend about 60 minutes on this section.
Answer ALL questions in this section.
Answer the questions requiring a written answer in the spaces provided.
Some questions will require you to save code in a specified format.
1 HTML is used to structure web pages.
(a) Give one reason why it is important to write organised code when creating
web pages.

(1)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

(b) Figure 1 shows how a description list should be displayed in a browser.

The HTML code should:
•

display the heading Clean and Gleam

•

underline the text How much do you know about cleaning?

•

display the rest of the text as a description list.

Clean and Gleam
How much do you know about cleaning?
Domestic cleaning
An activity that is part of maintaining cleanliness in the home on a regular basis
Laundry
Clothes and linen that need to be washed or that have been newly washed
Ironing
The process of smoothing or pressing with a heated iron
Figure 1

The page does not display as intended because there are two errors in the
HTML code.

Open file Q01b.html in a browser and in your editor to identify the errors.

Amend the code to correct the two errors.

Save your amended code as Q01bFINISHED.html

2

*P71386A0220*

(2)



(c) A web page needs to display the table shown in Figure 2.
Some of our services
Ironing

Laundry
Figure 2

The table must include:
•

a border

•

the table heading Some of our services

•

the table data Ironing and Laundry.

Write the HTML code to create the table.

(3)

Use this space to write your code.



*P71386A0320*

3

Turn over

(d) Figure 3 shows HTML code.
6

<p tabindex="3">Daily cleaning service</p>

7

<p tabindex="1">Weekly cleaning service</p>

8

<p tabindex="2">Monthly cleaning service</p>

Figure 3

Describe the effect of the tabindex element in this code.

(2)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

(Total for Question 1 = 8 marks)

4

*P71386A0420*



2 CSS is used by browsers to style HTML elements.
(a) Figure 4 shows CSS code and HTML code.
2

div + p {

3
4
5

font-size: 40px;
}
</style>

6

</head>

7

<body>

8

<div>

9

<p>Review from our customers</p>

10

<p>Excellent. 5 stars or more</p>

11

</div>

12

<p>Highly recommend. Used them for years</p>

13

<p>Fabulous service. I would not go anywhere else</p>

Figure 4

(i) The + selector is used in line 2 of the CSS code.

Give the name of this selector.

(1)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

(ii) Describe the effect of the CSS code in lines 2 to 4.

(2)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

(b) Explain one reason why web developers use web-safe fonts.

(2)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .



*P71386A0520*

5

Turn over

(c) A web page uses an image sprite.
Figure 5 shows the image sprite house.png

CSS can be used to show different sections of the image sprite.

Figure 5

When the page loads the user
will see this section of the
image sprite.

When the user hovers over the
image it will be replaced with
this section of the image sprite.

Open file Q02c.html in your editor.

Amend the CSS code to implement the hover effect.

Save your amended code as Q02cFINISHED.html

6

*P71386A0620*

(3)



(d) A web page contains shapes that need formatting and positioning.

The rectangle must be:
•

black

•

500 pixels high

•

800 pixels wide.

The square must:
•

be blue

•

fit inside the rectangle.

The circle must:
•

be yellow

•

fit inside the square.

Open the file Q02d.html in your editor.

Amend the HTML and CSS code to format and position the shapes.

Save your amended code as Q02dFINISHED.html

(5)
(Total for Question 2 = 13 marks)



*P71386A0720*

7

Turn over

3 JavaScript provides interactivity for web pages.
(a) Figure 6 shows the JavaScript used to calculate electricity charges for a customer.
1

var unitsUsed = prompt("Enter the number of units used")

2

var customerType = prompt("Enter the customer type")

3

var chargePerUnit = 3

4

var totalCharges = 0

5

var discount = 0

6
7

if (unitsUsed <= 199) {

8

chargePerUnit = 1

9

} else if (unitsUsed <= 400) {

10

chargePerUnit = 2

11

}

12

if (customerType == "Loyal") {

13
14

discount = 5
}

15
16

totalCharges = unitsUsed * chargePerUnit – discount

17

alert("The total charges are: " + totalCharges)
Figure 6

(i) Complete the table to show the variable values at the end of the code using
these inputs:

unitsUsed: 200
customerType: New
Variable

(3)
Value

chargePerUnit
discount
totalCharges

(ii) State the purpose of + in line 17 of the code.

(1)

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

8

*P71386A0820*



(b) Open file Q03b.html in your editor.

When the page loads the JavaScript code:
•

sets the background colour of the page to white

•

hides the image of the cross

•

sets the width of the image of the cleaners.

When the image of the cleaners is clicked the JavaScript code:
•

sets the background colour of the page to black

•

shows the image of the cross

•

enlarges the image of the cleaners

•

displays the text Some of our wonderful cleaners above the image of
the cleaners

•

sets the colour of the text to white.

When the image of the cross is clicked the JavaScript code resets the page back to
the original settings.

The JavaScript code is incomplete, which means clicking the image of the
cleaners does not function correctly.

Amend the JavaScript code so that clicking the image of the cleaners
functions correctly.

Save your amended code as Q03bFINISHED.html

(4)

(c) Open Q03c.html in your editor.

The JavaScript code contains an incomplete function that should display the
user’s choice of cleaning frequency in a suitable message.

Amend the JavaScript code to complete the function.

Save your amended code as Q03cFINISHED.html

(2)
(Total for Question 3 = 10 marks)



*P71386A0920*

9

Turn over

BLANK PAGE
SECTION B BEGINS ON THE NEXT PAGE.

10

*P71386A01020*



SECTION B
You are advised to spend about 120 minutes on this section.
Answer ALL questions in this section.
Answer the questions requiring a written answer in the spaces provided.
Some questions will require you to save code in a specified format.
4 Clean and Gleam needs a web page.
A wireframe and a style guide have been provided.
Figure 7 shows the wireframe.
A mock-up, in PDF format, can be found in the assets folder.

logo.jpg

Clean and Gleam
Content

Text area

Content

Text area

Image area

About us

Images

about-us.txt

window.jpg

Customer Reviews

customerreviews.txt

Services

ironing.jpg

vacuum.jpg

services.txt

staff.jpg

Image area

Header

1000 pixels

Footer

mirror.jpg
Email Us
1000 pixels

Figure 7



*P71386A01120*

11

Turn over

Overall page requirements
•

Use HTML5 elements to define the different parts of the page.

•

Use Arial font style.

•

Use an external style sheet.

•

Use suitable padding and/or margins.

Web Design Style Guide
Header
•

Set background colour to black (#000000).

•

Insert the text Clean and Gleam as shown.

•

Set font size of Clean and Gleam to 40 pixels.

•

Set font colour to white (#FFFFFF).

•

Embolden the text.

•

Insert the logo image as shown. The image can be found in the assets folder.

•

Set width of logo image to 100 pixels.

Content
•

Set background colour to beige (#F5F5DC).

Text area

12

•

Set width of the text area to 380 pixels.

•

Insert the headings About Us, Customer Reviews, and Services
as shown.

•

Set background colour of the headings to crimson (#C70039).

•

Set font size of the headings to 20 pixels.

•

Insert the text as shown. The text can be found in the assets folder.

•

Justify the About Us and Customer Reviews text.

•

Italicise the customer reviews text.

•

Set the services text to a bulleted list.

*P71386A01220*



Image area
•

Set width of the image area to 580 pixels.

•

Insert the heading Images as shown.

•

Set background colour of the heading to crimson (#C70039).

•

Insert the images as shown. The images can be found in the assets folder.

•

Set a border around each image as shown.

•

Set rounded corners on each image as shown.

Footer
•

Set background colour to black (#000000).

•

Insert the text Email Us as shown.

•

Create an email link from the text Email Us to [email protected]

•

Set font size to 14 pixels.

•

Set font colour of the email link to white (#FFFFFF), including when the user
hovers over it.

Develop a prototype for the web page for Clean and Gleam using the wireframe,
mock-up, style guide, images and text provided.
Save your files as Q04FINISHED.html and Q04FINISHED.css
(Total for Question 4 = 20 marks)



*P71386A01320*

13

Turn over

5 Wireframes, style guides and mock-ups can be used as part of the web
design process.
Assess how useful the wireframe, mock-up and style guide were in helping you
produce the prototype of the web page in Question 4.
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

14

*P71386A01420*



. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

(Total for Question 5 = 9 marks)



*P71386A01520*

15

Turn over

6 Clean and Gleam wants to expand the functionality of its website.
It wants to implement:
•

a change password page that allows a member of staff to change their password

•

a costs page that allows a user to select a type of customer and display
information that is relevant to that type of customer.

All of the required files are supplied in the Q06 folder.
No additional resources are required.
You only need to add HTML, JavaScript and comments to the existing files.
Change password page
changePassword.html contains an early prototype.
The code includes an array of passwords.
The contents of the array must not be changed.
Complete the prototype to allow a member of staff to change their password.
When the submit button is clicked an automated method must:
•

validate the input to ensure that:
•

a current password has been input

•

the current password input matches the first item in the array

•

a new password:

•

•

•

has been input

•

has exactly eight characters

•

has been confirmed

•

is not already an item in the array

a single error message is displayed if a requirement is not met and the user
cannot progress until the error is rectified. For example, Password must
have exactly eight characters will be displayed if the password is not the
correct length.

accept valid data ensuring that:
•

a suitable message that includes the current and new passwords is displayed

•

the form is cleared.

You must add suitable comments to your code to explain how it works.
Save your file as changePasswordFINISHED.html

16

*P71386A01620*



Costs page
costs.html contains an early prototype.
Complete the prototype.
It must use an automated method to:
•

hide everything except the drop-down box when the page loads

•

update the page when a selection is made from the drop-down box by
displaying:
•

the heading Costs

•

the paragraph text Hourly charge per cleaner – £11.00, if the selection is
Existing customer

•

the paragraph text Hourly charge per cleaner – £12.00 and a sign-up
button, if the selection is New Customer.

Figure 8 shows how the page will look when the selection is Existing customer.
Figure 9 shows how the page will look when the selection is New customer.
Select customer type: Existing customer

Select customer type: New customer

Costs

Costs

Hourly charge per cleaner – £11.00

Hourly charge per cleaner – £12.00
Sign up

Figure 8

Figure 9

You must add suitable comments to your code to explain how it works.
Save your file as costsFINISHED.html
(Total for Question 6 = 20 marks)
TOTAL FOR PAPER = 80 MARKS



*P71386A01720*

17

BLANK PAGE

18

*P71386A01820*



BLANK PAGE



*P71386A01920*

19

BLANK PAGE

20

*P71386A02020*



Advertisement