A good starting point for a Silex application.
Built with Flint for better performance.
- php >5.4 (5.5 recommended)
- composer
- phpunit
- xdebug
composer install
- make app/var/cache writable
- make app/var/logs writable
- configure database credentials (app/config/database.yml)
app/cli schema:sync
- serve index.php out of app/webroot
Add routes in app/config/routes.yml
- see
Symfony Routing for ref.
Add templates and template namespaces in app/config/twig.yml
.
Create modules in app/src
that group controllers and supporting class structures by following
PSR-4 conventions. Composer will set up the autoloader for you.
Create your own service providers and inject them into the Pimple container.
Silex is meant to be flexible - use a structure that makes sense for your problem domain.
Doctrine2 DBAL is used for queries.