Skip to content
This repository has been archived by the owner on Mar 23, 2019. It is now read-only.

Latest commit

 

History

History
41 lines (28 loc) · 1.17 KB

README.md

File metadata and controls

41 lines (28 loc) · 1.17 KB

Silex Scaffold

A good starting point for a Silex application.

Built with Flint for better performance.

Requirements

  • php >5.4 (5.5 recommended)
  • composer
  • phpunit
  • xdebug

Setup

  1. composer install
  2. make app/var/cache writable
  3. make app/var/logs writable
  4. configure database credentials (app/config/database.yml)
  5. app/cli schema:sync
  6. serve index.php out of app/webroot

Usage

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.