Download

Github

git clone https://github.com/Usbac/wolff.git

Composer

composer create-project usbac/wolff

Let's build something together

                    
system > web.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14
‹?php use Wolff\Core\Route; Route::any('/', [ Controller\Home::class, 'index', ]);

Create a route

                    
app > controllers > Home.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
‹?php namespace Controller; use Wolff\Core\View; class Home { public function index($req, $res) { View::render('home', [ 'meta' => 'My webpage', 'title' => 'Hello world', ]); } }

Create a controller

                    
app > views > home.wlf
1 2 3 4 5 6 7 8 9 10 11 12 13 14
<!DOCTYPE html> <head> <title>{{ $meta }}</title> </head> <body> <h2>{{ $title }}</h2> </body> </html>

Design the view

Latest releases

v4.0.1

  • 05/11/2021

    Fixed

    • Fix incompatibility of the count method of the Wolff\Core\DB class with some DB drivers.

    v4.0.0

  • 05/01/2021

    Added

    • Add language tag to the template engine.

    • Add optional seconds parameter to the clear method of the Wolff\Core\Cache class.

    • Add getFilename method to the Wolff\Core\Cache class.

    • Add getCode and writeJson methods to the Wolff\Core\Http\Response class.

    • Add support for dot notation in the get method of the Wolff\Core\Config class.

    • Add support for dynamic redirections to the Route system.

    • Add optional whitelist parameter to the local function of the standard library.

    • Add better overall performance.

    Changed

    • Change the function parameter of the Wolff\Core\Route class to accept an array containing the class and method to call ('[email protected]' now is [ Controller\Home::class, 'index' ]).

    • Change the default language from english to en.

    • Make the Logging system non-static.

    • The credential array keys dbms, server and name has been replaced by the key dsn in the Wolff\Core\DB and Wolff\Utils\Auth constructors.

    • Change the Maintenance system whitelist from a file to a PHP iterable value.

    • Change the cache files extension to tmp.

    • Change the optional gmdate parameter of the getRemainingTime and getVarTime methods of the Wolff\Core\Session class to a string, containing the format for the time.

    Removed

    • Remove the automatic controller's routing.

    • Remove the getSchema method of the Wolff\Core\DB class.

    • Remove the toUtf8 method of the Wolff\Utils\Str class.

    • Remove the count method of the Wolff\Core\Session class.

    • Remove the wolffVersion and isBool functions of the standard library.

    v3.2.2

  • 10/05/2020

    Changelog:

    • Fixed bug related to the fast query methods of the Wolff\Core\DB class not working with conditions.

    v3.2.1

  • 09/11/2020

    Changelog:

    • Fixed bug related to the init method of the Wolff\Core\Config class not throwing the right exception.
    • Fixed bug related to the getAllowedIPs and removeAllowedIP methods of the Wolff\Core\Maintenance class not throwing the right exception.

    Requirements

    • PHP 7.1 or higher
    • Composer

    Contact

    Requests and questions can be send to the email [email protected], you will be contacted shortly.

    Contributing

    Any contribution or support to this project in the form of a pull request will be highly appreciated. This can be done in both of the official repositories wolff and wolff-framework.