Theory Assignment 2 webdevev 2025
Theory Assignment 2 webdevev 2025
Question 2.
To connect an HTML page to a MySQL database, you cannot directly interact with the database using
HTML itself; instead, you need a server-side scripting language like PHP, Python, or Node.js to handle
the database connection and retrieve/insert data, which is then displayed on the HTML page through
dynamic content generated by the server-side script based on the data from the database. Discuss
the Key steps involved. (10)
Question 3.
a) Discuss the key points and features about database-driven websites giving examples. (10)
b) A database driven website has many advantages over a basic website. The most imperative
ones are presented below: (Discuss them)
• Content Management
• Future Expandability
• Improving Stability
• Cutting Production and Update Costs
• Data Storage
• More Efficiency
Question 4.
a) Explain how to add website code to GIT repository. (5)
b) Define GIT repository. (5)
c) Outline the various ways of getting a GIT repository. (5)
d) Distinguish between GIT and GitHub. (5)
e) Describe the installation and setting up of GIT. (5)
f) Explain any 10 GIT commands. (10)
g) Outline how to deploy push application code to online repository.(5)
h) Define feature branching. (2)
i) Outline qualities of feature branch deployments. (5)
j) Outline steps to merge branches to master in GIT. (5)
Question 5.
Discuss the following key practices to implement security on web pages:
$fileName = $_FILES['userFile']['name'];
$tmpName = $_FILES['userFile']['tmp_name'];
$uploadDir = "uploads/";
exit;
if (move_uploaded_file($tmpName, $targetPath)) {
} else {
Question 7.
a) There are 2 HTTP request methods: GET and POST. Differentiate between them. (4)
b) Describe the purpose, function and benefits of website frameworks. (9)
c) Discuss the types and examples of available website frameworks. (10)