Shop Project - Documentation
Developer Quickstart
Key first steps for new developers for local analysis and debugging.
Prerequisites
Ensure PHP 8.x and MySQL/MariaDB are running.
Set up local environment
Since the project is currently synchronized locally via Seafile and there is no public repository, I have developed a special "environment logic" to facilitate your entry. You can flexibly place this script in the root directory or in any parent folder where you manage multiple projects.\n Simply place your project folders as direct subfolders next to these environment files. The system automatically searches for entry points (like index.php, index.html, or public/index.php) and lists all found projects neatly and clearly in your browser.
Choose your operating system for specific installation instructions:
- Install and start XAMPP.
- Start Apache and MySQL through the XAMPP Control Panel.
- Set the database password (Linux compatibility).
- Click Shell next to MySQL in the XAMPP Control Panel.
- Sign in as
root:
mysql -u root
- Set the password to
dev:
ALTER USER 'root'@'localhost' IDENTIFIED BY 'dev'; FLUSH PRIVILEGES; EXIT;
- Close the Shell window.
- Enable the phpMyAdmin login page.
- Click Config next to Apache and open
config.inc.php(C:/xampp/phpMyAdmin/config.inc.php). - Find
auth_typeand enable cookie authentication:
$cfg['Servers'][$i]['auth_type'] = 'cookie';
- The password line must remain empty:
$cfg['Servers'][$i]['password'] = '';
- Save the file, open
http://localhost/phpmyadmin/, and sign in withrootanddev.
- Create the database.
- Create a new database named
web_shop_dbin phpMyAdmin.
- Install and configure Xdebug.
- Open
http://localhost/dashboard/phpinfo.phpand copy the complete output. - Paste it into the
https://xdebug.org/wizard, run the analysis, and download the suggested DLL. - Move the DLL to
C:/xampp/php/ext/and rename it tophp_xdebug.dll. - Click Config next to Apache and open
php.ini(C:/xampp/php/php.ini). Findoutput_bufferingand replace the line with:
; output_buffering=4096 output_buffering=off
- Add this block at the end of the file:
[Xdebug] zend_extension = "c:/xampp/php/ext/php_xdebug.dll" xdebug.mode = debug xdebug.start_with_request = yes xdebug.client_port = 9003 xdebug.log = "c:/xampp/tmp/xdebug.log"
- Restart Apache.
- Set up the project and run the database setup.
- Synchronize the project folder to
C:/xampp/htdocs/brulsim/. - Open
https://shop.brulsim.ch/dev/dev.php?tool=setup-dbin the browser, run the setup, and then open the project.
- Move the project to /var/www/html/ and fix permissions:
sudo chown -R $USER:$USER /var/www/html/. - Enable password login for MariaDB root:
ALTER USER 'root'@'localhost' IDENTIFIED VIA mysql_native_password USING PASSWORD('dev');. - If using DBeaver as a Flatpak, enable network access with:
flatpak override --user --share=network io.dbeaver.DBeaverCommunity.
Array
Shop HomeArray
- Start the shop and check node/lang/nav_UID parameters.
- Check cRouter and cSession for routing errors.
- URL example: https://shop.brulsim.ch/?node=article&lang=EN&nav_UID=3