0% found this document useful (0 votes)
19 views4 pages

CSC 409 Group 1 Project

This document provides an introduction to a group project on server-side programming using PHP and MySQL. It discusses the three layers of full stack web development including the front-end, back-end, and database. PHP and MySQL are introduced as the programming language and database tool to be used. Key aspects of PHP and MySQL are outlined, including what they are, how they work together, and an example code showing an INSERT query from PHP to MySQL.

Uploaded by

Excel Stephen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views4 pages

CSC 409 Group 1 Project

This document provides an introduction to a group project on server-side programming using PHP and MySQL. It discusses the three layers of full stack web development including the front-end, back-end, and database. PHP and MySQL are introduced as the programming language and database tool to be used. Key aspects of PHP and MySQL are outlined, including what they are, how they work together, and an example code showing an INSERT query from PHP to MySQL.

Uploaded by

Excel Stephen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

CSC 409 GROUP 1 PROJECT ON

SERVER-SIDE PROGRAMMING USING PHP AND MYSQL

1.0. Introduction to Server-side Programming

In a full stack web development, there are three layers. They are the front-end, back-end (i.e.
the server-side) and the database. These are all considered a part of the full stack web
development tools. The front-end is where the user interacts with the system. The backend is
where the programming of the website is done.

Server side technology are a set of tools and programming languages that are used to design,
build and maintain server side operations of a web application. Examples of server side
programming languages include; PHP, JavaScript, Perl, Python, Ruby and Java. While
example of frameworks for server side programming includes; NodeJS, Django, Flask,
Express, Ruby on Rails, ASP.NET, SpringBoot etc.

A database is an organized collection of structured information, or data, typically stored


electronically in a computer system. A database is usually controlled by a database
management system (DBMS). Together, the data and the DBMS, along with the applications
that are associated with them, are referred to as a database system, often shortened to just
database.

Data within the most common types of databases in operation today is typically modeled in
rows and columns in a series of tables to make processing and data querying efficient. The
data can then be easily accessed, managed, modified, updated, controlled, and organized.
Most databases use structured query language (SQL) for writing and querying data.
Examples of SQL database includes; Oracle 12c, MySQL, MS SQL Server, PostgreSQL,
MongoDB, MariaDB, DB2, SAP HANA etc.

For this project, we are using PHP as the server side programming language, and the MySQL
database as the database tool.
2.0. Introduction to PHP and MySQL web development
2.1. What is PHP?

PHP originally stood for Personal Home Page, but was changed in line with the GNU
recursive naming convention (GNU means Gnu’s Not Unix) and now stands for PHP
Hypertext Preprocessor.

PHP is a server-side scripting language designed specifically for the web. Within an
HTML page, you can embed PHP code that will be executed each time the page is
visited. The PHP code is interpreted at the Web servers and generates HTML or other
output that the visitor will see.

2.2. What is MySQL?

MySQL is a very fast, robust, relational database management system (RDBMS). The
MySQL server controls access to your data to ensure that multiple users can work with it
concurrently, to provide fast access to it, and ensures that only authorized users can
obtain access. Hence, MySQL is a multi-user, multi-threaded server. It uses SQL
(structured Query Language), which is the standard query language worldwide. MySQL
is now available under an Open source license, but commercial licenses are also available
if required.

2.3. Code to show how PHP and MySQL works

This PHP code shows the query of the INSERT statement from the MySQL query
statements;

<?php
$servername = "localhost";
$username = "username";
$password = "password";
$dbname = "myDB";

// Create connection
$conn = new mysqli($servername, $username, $password, $dbname);
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}

// SQL INSERT statement


$sql = "INSERT INTO MyGuests (firstname, lastname, email)
VALUES ('John', 'Doe', '[email protected]')";

// Sending messages
if ($conn->query($sql) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " . $sql . "<br>" . $conn->error;
}

// Close connection
$conn->close();
?>

REFERENCES

Welling, L., & Thompson, L. (2003). PHP and MySQL Web Development (2 nd ed.). Sams
Publishing

Crampete. (2019, August 09). Introduction to server-side programming languages. Crampete.


https://medium.com/@crampeteb/introduction-to-server-side-programming-languages-
ad97fbb3f852

Oracle. (n.d). What Is a Database?. Oracle. https://www.oracle.com/database/what-is-database/

You might also like