gollumeo / php-oop
A legacy PHP (>= 8.2) OOP boilerplate
Requires
- ext-pdo: *
- bramus/router: ^1.6
- filp/whoops: ^2.15
- symfony/console: ^6.0
- vlucas/phpdotenv: ^5.6
Requires (Dev)
- symfony/var-dumper: ^6.2
README
A simple PHP OOP (Object-Oriented Programming) project.
Requirements
This project requires the following:
- PHP 7.4 or higher
- Composer
- Node 18 or higher
- Valet or Herd (optional)
Installation
To install this project, you'll need Composer. Follow these steps:
- Open your terminal.
- Run the following command to create a new project:
composer create-project gollumeo/php-oop my-project
- You'll be prompted into picking your CSS flavor.
- Navigate into your project directory:
cd my-project
Development Server
To run the development server, you have several options depending on your environment.
Using PHP Built-in Server
If you are not using Valet or Herd, you can use PHP's built-in server:
php -S localhost:8000 -t public/
Using Valet/Herd
Using Valet
If you are using Valet, you can run the following command:
valet link
Then, open your browser and visit http://my-project.test
.
Using Herd
If you are using Herd, you can run the following command:
herd link
Then, open your browser and visit http://my-project.test
.
Contributing
Feel free to contribute to this project! You can also comment on the issues or create new ones foe next features or any issue to be solved!
Coming Soon(tm)
- Actual doc on how to use/set up new data flow:
- setting up the model properties;
- handling requests and responses within the controller
- sending data from the controller to the view
License
This project is open-sourced software licensed under the MIT license.