LESSON5-XAMPP Flashcards
is a popular cross-platform web server solution stack package developed by Apache Friends, consisting mainly of Apache HTTP Server, MariaDB database (previously MySQL), and interpreters for scripts written in the PHP and Perl programming languages.
XAMPP
is a free and open-source administration tool for MySQL and MariaDB databases.
PHPMyAdmin
simplifies setting up a local web server environment for PHP development. It bundles all the necessary components, including the Apache web server, MySQL database, PHP, and Perl, making it easy to install and configure on various operating systems such as Windows, macOS, and Linux.
XAMPP
is a web-based interface for managing MySQL databases. It provides a userfriendly graphical interface for tasks such as creating, deleting, and modifying databases, tables, and records.
_________ also allows users to execute SQL queries, import and export data, and manage database
users and privileges.
PHPMyAdmin
is a feature used to execute the same (or similar) SQL statements repeatedly with high efficiency.
Prepared Statements
involves adding new data entries to the database.
Create(Insert)
$sql = “INSERT INTO users (name, email) VALUES (‘$name’, ‘$email’)”;
involves fetching data from the database and displaying it to users.
Read(Retrieve)
$sql = “SELECT * FROM users”;
$result = mysqli_query($conn, $sql);
allows users to modify existing data entries in the database.
Update
$sql = “UPDATE users SET name=’$name’, email=’$email’ WHERE id=$id”;
involves removing data entries from the database.
Delete
$sql = “DELETE FROM users WHERE id=$id”;
Database Connection
<?php
$servername='localhost'; $username='root'; $password=''; $dbname = "db_name"; $dbconnect=mysqli_connect($servername,$username,$password,"$dbname"); if(!$dbconnect){ die('Could not Connect MySql Server:' . mysqli_connect_error()); }
?>