There are basically two main types of websites
static and
dynamic/database driven website
A static site is one that is usually written in plain HTML and what is in the code of the page, is what is displayed to the user. A database driven/dynamic site is one that is written using a server-side scripting language such as PHP and has most of its content in a database.
Benefits of a Database Driven Website
Database driven websites can provide much more functionality than a static site can. This could include:
Enabling also non-technical users to provide content for the website.
Shopping cart
You can provide advanced search functionality that enables users to filter the results based on a given field. They can then sort those results by a field - say "Price" or "Date".
Customized homepage
You can allow your users to perform tasks such as registering for a newsletter, post questions to your forums, provide comments on a blog, update their profile, etc.
To create a database driven website, you need the following skills:
You need to be able to:
build a static website in HTML/CSS and Javascript
write basic code using a server side scripting language such as PHP
You need to know how to write basic SQL
You need to be able to design/build a database.
In the assessment, you will create a database linked to a website where the material from the database can be displayed on the web page and next your you will be able to update the database via the website.
A web server, such as Apache web server
An application server that runs on your web server, such as PHP module for Apache
A web application interface language, such as PHP and MySQL database server
MAMP (how to download and what it is, help students download software on their devices)
Start servers/stop servers
Show how to access the website (localhost:8888)
Demonstrate the dynamic website and explain why it is called a dynamic website (search bar and dynamic nav)
Show and explain htdocs
Show and explain the files/folders in GGVS
Show how to access Mysql
Explain table, fields, records, how to search/sort on Mysql
Name conventions database eg field names, table names, data type
Show and explain how to connect to the database in your code (conn.php, servername, username and password)
Focus on top.php and bottom.php and the purpose of include in your code (avoid duplication, easy to modify as it is in one place in includes folder)
Show PHP in the code, similarities and differences between Python and PHP?
Focus on PHP code $ query, $result,$record set and how to check the number of records that match the criteria.