Installing XAMPP
Local development environment
XAMPP bundles Apache, MySQL, PHP, and phpMyAdmin in a single installation for Windows, macOS, and Linux. The recommended version for this course is XAMPP with PHP 8.x. After installation, start Apache and MySQL from the XAMPP Control Panel. Place the project in C:\xampp\htdocs\braintech or the appropriate folder on your system.
Installation steps
- Download XAMPP from apachefriends.org and run the installer.
- Select components: Apache, MySQL, PHP, phpMyAdmin.
- Start the Control Panel, launch Apache and MySQL (green status).
- In the browser, open http://localhost – you should see the XAMPP start page.
Checking the PHP version
Create a file info.php with the content <?php phpinfo(); ?> and open http://localhost/info.php. Check the PHP version and enabled extensions pdo_mysql and mbstring.
<?php
echo "Server radi: " . ($_SERVER["SERVER_SOFTWARE"] ?? "nepoznato");Working in the local environment
Create the folder htdocs/php-kurs inside XAMPP htdocs. Practice each new topic in a separate file (e.g. instalacija-xampp.php) to track your progress easily. Keep Developer Tools (F12) open – the Network and Console tabs speed up learning.
