\n\n\n\n(d) The user tries to find statistics for Aberdeen. However, they typed ‘Aberdene’ into the text box and the following web page was displayed.\n\nExplain how this database-driven website uses server-side scripting to produce the output above.","eduQuestionType":"Open ended","url":"https://simplestudy.cloud/gb/content/questions/scottish-higher/_/computing-science/web-design-and-development-implementation/tourist-website-statistics-serv-side-scripting-css","dateModified":"2025-09-28T20:20:21.269Z","inLanguage":"en","acceptedAnswer":{"@type":"ItemList","itemListElement":[{"@type":"ListItem","position":1,"name":"Explain why server-side scripting has been used to produce the statistics as shown on the web page above.","item":"Server-side scripting is used to dynamically generate content based on user input. In this case, when a user enters a city name, the server accesses the database that stores city statistics and retrieves the relevant data. This prevents local storage of large datasets on the client side and ensures that users can access real-time information without downloading extensive data to their browser."},{"@type":"ListItem","position":2,"name":"Write a CSS rule that makes H1 headings appear in Arial, centre aligned and green.","item":"```css\n#h1 {\n font-family: Arial;\n text-align: center;\n color: green;\n}\n```"},{"@type":"ListItem","position":3,"name":"Describe how CSS rules should be implemented to ensure that all of the web pages on the website have consistent formatting.","item":"To ensure consistent formatting across all web pages, CSS rules should be placed in an external stylesheet. This stylesheet can be linked to each HTML page using the `` tag in the `` section. This way, any changes made to the CSS file will automatically update the style across all pages."},{"@type":"ListItem","position":4,"name":"Complete the four missing lines of code to allow the Function Increase() to triple the width and height of the graphic...","item":"```html\nfunction Increase(x) {\n x.style.width = \"96px\";\n x.style.height = \"96px\";\n}\n\nfunction Normal(x) {\n x.style.width = \"32px\";\n x.style.height = \"32px\";\n}\n```"},{"@type":"ListItem","position":5,"name":"Explain how this database-driven website uses server-side scripting to produce the output above.","item":"This database-driven website uses server-side scripting to process user queries against a database. When a user inputs a location name, the script constructs a SQL query to search for matching entries in the database. If no match is found, it generates an appropriate output message, such as 'Sorry, we found no match for your location.' This facilitates dynamic responses based on user input."}]},"provider":{"@type":"EducationalOrganization","name":"SimpleStudy","logo":{"@type":"ImageObject","url":"https://cdn.simplestudy.cloud/assets/frontend/img/favicon.png","width":"192","height":"192"},"url":"https://simplestudy.cloud"},"offers":{"@type":"Offer","price":"0","priceCurrency":"GBP","availability":"https://schema.org/InStock","url":"https://simplestudy.cloud/signup/country"},"educationalLevel":"Scottish Highers","educationalAlignment":[{"@type":"AlignmentObject","alignmentType":"educationalSubject","targetName":"Computing Science"},{"@type":"AlignmentObject","alignmentType":"educationalTopic","targetName":"Web Design and Development-Implementation"}],"teaches":["Web Design and Development-Implementation for Scottish Highers Computing Science","Scottish Highers Computing Science exam preparation","Web Design and Development-Implementation exam questions"],"learningResourceType":["Exam Questions"],"audience":{"@type":"EducationalAudience","educationalRole":"Student","audienceType":"Scottish Highers"},"interactivityType":"active","isAccessibleForFree":true,"contentLocation":{"@type":"Place","name":"Online"},"publisher":{"@type":"EducationalOrganization","name":"SimpleStudy","logo":{"@type":"ImageObject","url":"https://cdn.simplestudy.cloud/assets/frontend/img/favicon.png","width":"192","height":"192"},"url":"https://simplestudy.cloud"},"review":{"@type":"Review","reviewRating":{"@type":"Rating","ratingValue":"5","bestRating":"5"},"author":{"@type":"Person","name":"SimpleStudy Student"},"reviewBody":"SimpleStudy made revision simple, with easy to study resources for Scottish Highers Computing Science."},"potentialAction":[{"@type":"ViewAction","target":"https://simplestudy.cloud/gb/content/questions/scottish-higher/_/computing-science/web-design-and-development-implementation/tourist-website-statistics-serv-side-scripting-css"},{"@type":"RegisterAction","target":"https://simplestudy.cloud/signup/country"}],"mainEntityOfPage":{"@type":"WebPage","speakable":{"@type":"SpeakableSpecification","cssSelector":["[data-seo-id=\"heading\"]"]},"breadcrumb":{"@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"SimpleStudy","item":"https://simplestudy.cloud"},{"@type":"ListItem","position":2,"name":"Scottish Highers","item":"https://simplestudy.cloud/scottish-higher"},{"@type":"ListItem","position":3,"name":"Computing Science","item":"https://simplestudy.cloud/scottish-higher/computing-science"},{"@type":"ListItem","position":4,"name":"A tourist website has a web page which displays statistics about towns and cities","item":"https://simplestudy.cloud/gb/content/questions/scottish-higher/_/computing-science/web-design-and-development-implementation/tourist-website-statistics-serv-side-scripting-css"}]}}}

Photo AI

A tourist website has a web page which displays statistics about towns and cities - Scottish Highers Computing Science - Question 13 - 2018

Question icon

Question 13

A-tourist-website-has-a-web-page-which-displays-statistics-about-towns-and-cities-Scottish Highers Computing Science-Question 13-2018.png

A tourist website has a web page which displays statistics about towns and cities. The user enters a name in the text box and clicks on the search button to display ... show full transcript

Worked Solution & Example Answer:A tourist website has a web page which displays statistics about towns and cities - Scottish Highers Computing Science - Question 13 - 2018

Step 1

Explain why server-side scripting has been used to produce the statistics as shown on the web page above.

96%

114 rated

Answer

Server-side scripting is used to dynamically generate content based on user input. In this case, when a user enters a city name, the server accesses the database that stores city statistics and retrieves the relevant data. This prevents local storage of large datasets on the client side and ensures that users can access real-time information without downloading extensive data to their browser.

Step 2

Write a CSS rule that makes H1 headings appear in Arial, centre aligned and green.

99%

104 rated

Answer

#h1 {
    font-family: Arial;
    text-align: center;
    color: green;
}

Step 3

Describe how CSS rules should be implemented to ensure that all of the web pages on the website have consistent formatting.

96%

101 rated

Answer

To ensure consistent formatting across all web pages, CSS rules should be placed in an external stylesheet. This stylesheet can be linked to each HTML page using the <link> tag in the <head> section. This way, any changes made to the CSS file will automatically update the style across all pages.

Step 4

Complete the four missing lines of code to allow the Function Increase() to triple the width and height of the graphic...

98%

120 rated

Answer

function Increase(x) {
    x.style.width = "96px";
    x.style.height = "96px";
}

function Normal(x) {
    x.style.width = "32px";
    x.style.height = "32px";
}

Step 5

Explain how this database-driven website uses server-side scripting to produce the output above.

97%

117 rated

Answer

This database-driven website uses server-side scripting to process user queries against a database. When a user inputs a location name, the script constructs a SQL query to search for matching entries in the database. If no match is found, it generates an appropriate output message, such as 'Sorry, we found no match for your location.' This facilitates dynamic responses based on user input.

Join the Scottish Highers students using SimpleStudy...

97% of Students

Report Improved Results

98% of Students

Recommend to friends

100,000+

Students Supported

1 Million+

Questions answered

;