PHP Classes

Mabs: Micro-framework for Web application development

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 257 All time: 7,840 This week: 455Up
Version License PHP version Categories
mabs-micro-framework 1.0.0MIT/X Consortium ...5.3.9PHP 5, Libraries
Description 

Author

This package is a micro-framework for Web application development.

It provides basic components to build simple Web applications like:

- Basic container
- Session service adapter
- Event dispatcher
- Router based on Symfony HttpFoundation

Picture of Mohamed Aymen Ben Slimane
  Performance   Level  

 

Documentation

Mabs Framework

Scrutinizer Code Quality Code Climate Build Status

Mabs is a PHP micro framework, speedy, light and easy to learn .

Features

  • Container
  • Event dispatcher
  • Routing
  • HttpFoundation (Symfony2 component)
  • An easy way to extend PHP libraries

Getting Started

Install

You may install the Mabs Framework with Composer (recommended).

$ composer require  mabslabs/mabs @dev

Quick start

// web/index.php
<?php

require_once __DIR__.'/../vendor/autoload.php';

$app = new Mabs\Application();

$app->get('hello/(name)', function ($name) {

    return 'Hello '.$name;
})->run();

More details

// web/index.php
<?php

require_once __DIR__.'/../vendor/autoload.php';
use  \Symfony\Component\HttpFoundation\RedirectResponse;

$app = new Mabs\Application();
$container = $app->getContainer();

$app->get('/', function () use ($container) {
    $url = $container['router']->generateUrl('hello_page', array('name' => 'World'));

    return new RedirectResponse($url);
});

$app->get('hello/(name)', function ($name) {

  return 'Hello '.$name;
}, 'hello_page');

$app->run();

License

This bundle is available under the MIT license.


  Files folder image Files (15)  
File Role Description
Files folder imagesrc (4 files, 4 directories)
Files folder imagetests (1 file)
Accessible without login Plain text file .travis.yml Data Auxiliary data
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. Auxiliary data
Accessible without login Plain text file phpunit.xml.dist Data Auxiliary data
Accessible without login Plain text file README.md Doc. Auxiliary data

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:257
This week:0
All time:7,840
This week:455Up