Controllers
Control every request, process data and return views with data to show.
Create a controller with BoosterCLI
$ php BoosterCLI make:controller "TheNameOfYourController"app/controllers/<?php
use Libs\BoosterORM\BoosterORM;
class Users
{
public function index()
{
}
public function create()
{
}
public function store()
{
}
public function search()
{
//access to search with $_REQUEST['search']
//example of query: where column = 1 AND otherColumn LIKE '%$_REQUEST['search']%'
//for filter more where (column = 1 AND otherColumn LIKE '%$_REQUEST['search']%') OR (column = 1 AND otherOneColumn LIKE '%$_REQUEST['search']%')
}
public function edit($id=null)
{
}
public function update($id=null)
{
}
public function show($id=null)
{
}
public function destroy($id=null)
{
}
}
?>Last updated