FeBe - Front-End, Back-End, MVC, PHP - Framework. Further information can be found in the "UseFeBe" menu in FeBe.
Implementation of functions and presentation of content, with HTML, CSS, JavaScript. Materialize CSS is used, JQuery as well as JS handlebars and JS code highlight.
Logic, data processing and database interaction. The backend is responsible for processing user requests, providing data, and communicating with the frontend. Different Cpmposer packages are used and SQLITE3. The database connection is established using PHP-PDO. It is therefore possible to use other databases as well. The templates are rendered with PHP handlebars.
The PHP framework is a collection of libraries, tools, and pre-built code designed to simplify the development of web applications using PHP. It provides a structure and set of rules to facilitate the development of efficient, scalable, and maintainable applications.
Composer is required to install the dependencies.
composer create-project it-m-h/FeBe testFebe --stability=dev
composer update
composer outdated
composer update --with-all-dependencies
composer update phpunit/phpunit
composer dump-autoload
git clone https://github.com/it-m-h/FeBe
cd FeBe
composer update
After that, navigate to the directory and configure the .gitignore file (exclude data, sites, and config). Update: To fetch the latest version.
git pull
Download the ZIP file and extract its contents.
cd goToFolderFrom_FeBe
composer update
PHP : C:\xampp\php\php.ini
- extension=pdo_sqlite
- extension=sqlite3
- extension=zip
PHP : C:\xampp\php\php.ini
LISTEN 55001
<VirtualHost *:55001>
DocumentRoot "C:\xampp\htdocs\testFebe\public"
</VirtualHost>
Browser: http://localhost:55001/
vHosts : C:\xampp\apache\conf\extra\httpd-vhosts.conf
<VirtualHost *:80>
Servername Page1.local
DocumentRoot "C:\xampp\htdocs\FeBe\public"
ErrorLog "logs/Page1.local-error.log"
CustomLog "logs/Page1.local-access.log" common
<Directory "C:\xampp\htdocs\FeBe\public">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
Browser: http://Page1.local/
- After modifying the httpd.conf file, the Apache server needs to be restarted.
- The httpd.conf file may need to be opened as an administrator.
- The httpd-vhosts.conf file is more suitable for virtual hosts, but the httpd.conf file is the main configuration file.
- In Windows, the hosts file can also be used to assign DNS names (for the local machine). The hosts file is located at: C:\Windows\System32\drivers\etc\hosts.
sudo -i
sudo apt update
sudo apt upgrade
apt install curl
apt install apache2
apt install php
apt install php-pdo
apt install php-zip
apt install php-curl
apt install php-xml
apt install php-cli
apt install unzip
nano /etc/php/8.1/apache2/php.ini
-- extension=curl aktivieren
a2enmod rewrite
service apache2 reload
service apache2 restart
cd /var/www
wget https://github.com/it-m-h/FeBe/archive/refs/heads/main.zip
unzip main.zip
mv FeBe-main FeBe
cd FeBe
composer update
chown -R www-data:www-data /var/www/FeBe
chgrp -R www-data /var/www/FeBe
Apache start and stop after configuration changes.
nano /etc/apache2/sites-available/000-default.conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot "/var/www/html/FeBe/public"
<Directory "/var/www/html/FeBe/public">
AllowOverride All
</Directory>
</VirtualHost>
DB - Connection with PDO
extension=pdo_sqlite
composer require --dev phpunit/phpunit
composer remove --dev phpunit/phpunit
class MyUserTest extends PHPUnit\Framework\TestCase
{
public function testHome()
{
}
}
php vendor/bin/phpunit tests/TestUser.php --colors
composer require --dev phpstan/phpstan
composer remove --dev phpstan/phpstan
cd C:\xampp\htdocs\GIT_Project\it-m-h\FeBe
php vendor/bin/phpstan analyse -l 9 app
php vendor/bin/phpstan analyse -l 9 lib
php vendor/bin/phpstan analyse -l 9 lib/Auth.php
php vendor/bin/phpstan analyse -l 9 lib/Database.php
parameters:
ignoreErrors:
- '#Cannot access an offset on mixed#'
- '#Constant BASEPATH not found.#'
- '#Constant DURATION not found.#'
git tag
git tag -a v0.1.5 -m "Version 0.1.5"
git push origin v0.1.5