Coder Social home page Coder Social logo

marxvn / slim3-eloquent-skeleton Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mrcoco/slim3-eloquent-skeleton

0.0 2.0 0.0 342 KB

This is a simple skeleton project fork from akrabat/slim3-skeleton that includes scaffold tool, migrations,auth,Twig Twig, Flash messages, eloquent ORM and Monolog.

License: BSD 3-Clause "New" or "Revised" License

PHP 88.68% HTML 8.92% ApacheConf 0.88% CSS 0.30% JavaScript 1.23%

slim3-eloquent-skeleton's Introduction

Slim 3 Skeleton

This is a simple skeleton project fork from akrabat/slim3-skeleton that includes scaffold tool, migrations,auth,Twig, Flash messages, eloquent ORM and Monolog.

Create your project:

$ composer create-project -n -s dev mrcoco/slim3-eloquent-skeleton my-app

Run it:

  1. $ cd my-app
  2. Change database setting app\setting.php
  3. $ vendor/davedevelopment/phpmig/bin/phpmig migrate
  4. $ php -S 0.0.0.0:8888 -t public public/index.php
  5. Browse to http://localhost:8888

Key directories

  • app: Application code
  • app/src: All class files within the App namespace
  • app/templates: Twig template files
  • cache/twig: Twig's Autocreated cache files
  • log: Log files
  • public: Webserver root
  • vendor: Composer dependencies

Key files

  • public/index.php: Entry point to application
  • app/settings.php: Configuration
  • app/dependencies.php: Services for Pimple
  • app/middleware.php: Application middleware
  • app/routes.php: All application routes are here
  • app/src/Action/HomeAction.php: Action class for the home page
  • app/templates/home.twig: Twig template file for the home page

CLI Tools

  • Currently there are 3 supported commands:
  • php cli.php create:action MyActionClassName
  • php cli.php create:middleware MyMiddlewareClassName
  • php cli.php create:model MyModelClassName
  • php cli.php create:scaffold MyModuleName

Migration

  • migrate all data

  • php cli.php migrate

  • Confirmation of status

  • php cli.php status

  • Creating // migration file

  • php cli.php generate [MigrationName]

  • //Execution of migration

  • php cli.php migration

  • // I one Back

  • php cli.php rollback

  • // Return all

  • php cli.php rollback -t 0

  • // Go back to the time of completion of the specified MigrationID

  • php cli.php rollback -t [MigrationID]

  • // Only specified MigrationID the migration / roll back

  • php cli.php [up | down] [MigrationID]

Demo User:

  1. admin username: [email protected] password: password
  2. moderator username: [email protected] password: password
  3. user username: [email protected] password: password

slim3-eloquent-skeleton's People

Contributors

mrcoco avatar

Watchers

James Cloos avatar QiPT avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.