junker/controller-service-provider

Controller Service Provider for Silex

0.3.0 2020-06-18 19:19 UTC

This package is auto-updated.

Last update: 2024-11-19 04:32:49 UTC


README

Controller Service Provider for Silex

Requirements

silex 2.x

Installation

The best way to install ControllerServiceProvider is to use a Composer:

php composer.phar require junker/controller-service-provider

Examples

use Junker\Silex\Provider\ControllerServiceProvider;

$app->register(new ControllerServiceProvider());

$app->get('/', 'AppController::index');

Controller example:

use Junker\Silex\Controller;

class AppController extends Controller
{

	public function index()
	{
		$app = $this->app;
		$request = $this->request;

		return 'hello';
	}
	
}