Before launching a website into the wild, it needs to be built and tested locally. This ensures everything works smoothly without affecting a live server. For this portfolio, I utilized a classic LAMP stack approach (Linux, Apache, MySQL, PHP) but developed it on a Windows environment using XAMPP.
1. Installing XAMPP
XAMPP is an incredibly useful free tool that instantly bundles and configures the Apache web server, the MariaDB/MySQL database engine, and PHP functionality into one easy-to-use control panel on your local computer.
Placeholder: Take a screenshot of your XAMPP Control Panel running Apache and MySQL.
2. Project Directory Structure
For your computer to actually serve the website locally, the project files must be placed within Apache's designated web root folder. By default in XAMPP on Windows, this is the C:\xampp\htdocs\ directory.
I created a sub-folder named PersonalWebsite and placed all my HTML, PHP, CSS, and Javascript files inside of it.
Placeholder: Take a screenshot of the project folder open in your file explorer.
3. Viewing Localhost
With the files secured in the htdocs directory and the Apache module actively running in XAMPP, the local server is completely active.
Simply opening a web browser and typing the directory path http://localhost/PersonalWebsite/ executes the PHP scripts and serves the completed website just as it will appear once formally deployed.