PHPackages                             hummel/php-frame - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. hummel/php-frame

ActiveLibrary[Framework](/categories/framework)

hummel/php-frame
================

0.33(3y ago)020PHPPHP &gt;=7.0.0

Since Aug 9Pushed 2y ago1 watchersCompare

[ Source](https://github.com/HummelJulien/php-frame)[ Packagist](https://packagist.org/packages/hummel/php-frame)[ RSS](/packages/hummel-php-frame/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (9)Used By (0)

Package Name: hummel/php-frame
==============================

[](#package-name-hummelphp-frame)

I tried to respect the SOLID convention and follow the best practices.
----------------------------------------------------------------------

[](#i-tried-to-respect-the-solid-convention-and-follow-the-best-practices)

### For CDA and other PHP projects.

[](#for-cda-and-other-php-projects)

Installation:
-------------

[](#installation)

```
composer require hummel/php-frame
```

### If you want contribute to the projet please do so on [Github](https://github.com/HummelJulien/php-frame).

[](#if-you-want-contribute-to-the-projet-please-do-so-on-github)

#### Ask me and I will add you as a ***collaborator***

[](#ask-me-and-i-will-add-you-as-a-collaborator)

```
composer require hummel/php-frame --prefer-source
```

### First time setup:

[](#first-time-setup)

- Copy the content of folder resources to your root project folder
- Config two files in config folder: `pdo.yaml` and `routes.yaml`
- Config your apache server to use as document root the folder public

example of apache config:

```

    ServerName localhost
    DocumentRoot /var/www/html/public

        AllowOverride All
        Require all granted

```

Routes:
-------

[](#routes)

example: config/routes.yaml

```
demo:                                                         # route name
  routeUri: /user/{id}                                        # route uri with capture parameters
  controller: Hummel\PhpFrame\Controllers\DemoController      # controller class name
  action: showOnce                                            # call methode
  methode: GET/POST                                           # get/post/put/delete
  parameters:                         # parameters for the methode
      id:
        type: int             # int, string, float
        regex: /^[0-9]{1,3}$/ # regex for validation
```

Model:
------

[](#model)

Models are the main data structure of the application. Is auto bind to the database if you repect the convention of my frame.

```
