Implementation (HTML) (SQA National 5 Computing Science): Exam Questions

Exam code: X816 75

38 mins11 questions
1
2 marks

Find Me An Owner dog rescue centre is creating a new website.

Each dog has its own web page. The home page contains links to all of these pages. One of the pages is shown below.

Web page for Dudley, a 7-year-old Labrador from Inverness, seeking a home. Black and white image of Dudley on grass, rated 4 stars for friendliness.

The following HTML code is added to each dog’s web page.

<p> Back to the home page <a href= "home.html"> click here
</a>
</p>

Show how this code would be displayed when viewed in a browser.

2
3 marks

MoveIt estate agency is developing a new website.

The following code is used to create the home page for the estate agent’s website. The home page includes a heading, a video, a welcome message and the company logo shown below.

Black arrow pointing right next to the letters "MI" in a rectangular box, suggesting directional or locational guidance.
…
<style>
h1 {text-align:right;font-size:24pt}
.pageText {text-align:left;font-size:12pt}
</style>
…
<h1 class="pageText"> MoveIt Estate Agents </h1>
<video width="400" height="300" controls>
<source src="intro.mp4">
</video>
<p class="pageText"> Welcome to MoveIt Estate Agents </p>
<img src="logo.jpg" width="200" height="100">
…

Draw how the home page will look when viewed in a browser. Some of the content has already been added.

3
2 marks

Explain the difference between absolute and relative addressing.

4
6 marks

A travel website about Italy has a home page containing a list of cities. The home page is shown below.

Black and white image of Pisa's Leaning Tower and Cathedral under a cloudy sky, with text promoting Italian cities Pisa and Rome.

All web pages and media are stored in folders as shown below.

File directory with website folder containing Home, Pisa, Rome, and Assets. Assets folder includes Colosseum, LeaningTower, Romeinfo, and Rome files.

A hyperlink to the Pisa.html page is to be added to the home page as shown below.

Visit these Italian cities

  • Pisa

  • Rome

Complete the code below that would implement this list

<p>Visit these Italian cities</p>

[3]

(ii)Complete the HTML code below to add the sound file to the Rome.html web page.

[3]

<.............................Controls>
<source src="..............................................."
type="audio/mpeg">
<_/.........................................................>
5a
4 marks

Gone Away travel is a holiday booking website. Below is the home page for the website.

Web page featuring black and white images of Naples with Vesuvius, Copenhagen's harbour, and Egypt with the Sphinx and pyramids.

The following HTML and CSS is for a web page containing information about a trip to Naples.

style.css

body{
background-color:lightblue;
}
img{
height:200px;
width:250px;
}
h1{
font-family:Helvetica;
font-size:14px;
}
div{
background-color:white;
}
#city{
text-align:center;
font-size:20px;
}
p{
text-align:center;
font-size:12px;
}

naples.html

<!doctype HTML>
<html>
<head>
<title>Gone Away Travel - Naples</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<h1>Gone Away Travel</h1>
<h1 id="city">Naples</h1>
<p>Come visit the lovely Naples, the third largest city in
Italy. Home to the best pizza in the world. View our
pictures below to help make up your mind.</p>
<div>
<img src="Media/naples1.png">
<p class="description">Stunning view of the Naples bay</p>
</div>
<div>
<img src="Media/naples2.png">
<p class="description">One of the many food markets in
Naples</p>
</div>
</body>
</html>

(i) The description of each photograph is to be right aligned, use Arial font and be the same size as the other paragraphs on the page.

Write a single CSS rule that would only style the descriptions

[3]

..............................................{

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

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

}

(ii) The hyperlink below can be found on the Naples information page.

<a href="www.NaplesCity.co.uk">Official Naples city
guide</a>

State the type of addressing used in the hyperlink.

[1]

5b
3 marks

A video tour of Naples will be added to the web page. All media files for the website are stored in a folder called ‘Media’ as shown below.

File explorer displaying a folder named "website" with HTML files and a "Media" subfolder containing two images, "naples1," "naples2," and a video "naplesTour.mp4".

Using this structure, complete the following code so that the video naplesTour.mp4 is displayed on the naples.html page with the following dimensions.

Rectangular video thumbnail with a play button for naplesTour.mp4, dimensions 350x300 pixels.

<video ..............................................................................controls>


<source src= .................................................................... type= "video/mp4">


</video>

6
3 marks

Blockland theme park is developing a new website for visitors.

The following code is used to create the home page.

<!doctype html>
<html>
<head>
<title>Blockland Home Page</title>
<style>
body{background-color:lightblue;font-family:arial;}
img{height:150px; width:150px;}
h1{font-family:helvetica; font-size:24pt; text-align:center;}
.openSection{text-align:left;}
div{background-color:white; font-size:12pt;}
</style>
</head>
<body>
<img src="blocklandLogo.jpg" alt="Blockland Logo">
<h1>Welcome to Blockland!</h1>
<div>
<h1 class="openSection">Ultimate Day Out</h1>
<p>With an amazing themed room to suit every Block Lover including
rapid race cars, terrifying tarantulas and spectacular space there
is something for the whole family.</p>
<a href="parkRides.html">Click here to view the rides in the
park</a>
</div>
…
<a href="parkShop.html">Click here to browse the shop</a>
</body>
</html>

The following code is to be added to the website.

…
<p>New Rides</p>
<ul>
<li><a href="blockCars.html">The Block Cars</a></li>
<li>The Mystical Forest</li>
<li>The Lizard</li>
</ul>
…

Draw how this code would look when viewed in a browser.

7
1 mark

The Armin Fair website allows customers to buy tickets for shows taking place during the fair.

The web page for the Bracken Stage is shown below.

Webpage for The Armin Fair shows performers Shannon Duffy and Twig and Leaf on The Bracken Stage, with ticket prices and a buy option.

The web page contains internal hyperlinks.

Describe what is meant by an internal hyperlink.

8
4 marks

The Vulpes fox charity would like a website to increase public knowledge of foxes.

All the sounds used on the website are stored in a folder called ‘media’ in the following locations.

File directory view showing two columns: left lists HTML files and media folder under 'website > vulpes'; right shows MP3 files in 'media' folder.

Using this structure, complete the following code to play the sound ‘redFoxCry.mp3’ when the play button is pressed on the redFox web page.

[3]

<.........................................controls>


<source src= ".........................................................................
"type= "audio/mpeg">


</>

(ii) Upon testing, the fox sounds were found to take too long to download. Describe how the file size can be reduced without altering the length of the sound.

[1]

9
1 mark

A school website contains a link to the Scottish Qualifications Authority website. State the type of link used.

10
2 marks

Dog Day Care Centre requires a website to advertise their business. The following design is developed.

Cartoon banner of a dog day care website with photo of dog in field. Includes text about services, weather accommodations, and dog care details.

All the images used on the website are stored in a folder called ‘Graphics’ in the following location.

File explorer showing folders: 'graphics', and files: 'logo.gif', 'dog.jpg', 'map.jpg', 'walkRoute.jpg', 'home.html', 'services.html', 'photos.html', 'contact.html'.

Using this structure, complete the following code so that the graphic dog.jpg is displayed on the services.html page.

<img src="......................................................................................"/>

11a
6 marks

Katrina’s Cars is a car auction website. The HTML and CSS code for the home page is shown below.

(i) Draw how this web page will look when viewed in a browser. Some of the content has already been added.

[4]

Web browser window titled “Katrina’s Cars” with a simple car logo and URL "http://www.katrinascars.co.uk".

(ii) The following CSS is added to the website so that the text of any additional car for auction is coloured red.

.newCar{color:red;}

Katrina’s Cars asks for the following car to be added to the web page.

Morcodes GLS

Complete the missing line of code below to add the car.

[2]

<ul>
<li>Maxi Cupar</li>
<li>Mizdo CX-5</li>
<li>Oodi TT</li>
............................................
</ul>
11b
1 mark

The following HTML is to be added to the website.

<a href="carWeek.html">Car of the Week</a>

State the purpose of adding this HTML to the website.