2017 © Pedro Peláez
 

library slim-eloquent

Use Eloquent ORM in Slim 3

image

overflowsith/slim-eloquent

Use Eloquent ORM in Slim 3

  • Monday, November 30, 2015
  • by overflowsith
  • Repository
  • 1 Watchers
  • 4 Stars
  • 43 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 5 % Grown

The README.md

Eloquent ORM within Slim 3

This is a light and dirty wrapper for using Eloquent ORM., (*1)

Usage

 'mysql',
    'host'      => '127.0.0.1',
    'database'  => 'database',
    'username'  => '',
    'password'  => '',
    'charset'   => 'utf8',
    'collation' => 'utf8_unicode_ci',
    'prefix'    => '',
];

Overflowsith\SlimEloquent\Eloquent::boot($dbSettings);

class User extends Overflowsith\SlimEloquent\Model
{
}

$app->get('/', function ($request, $response, $args) use ($app) {

    $userCount = User::count();

    $response->write("# of users: " . $userCount);

    return $response;

});

$app->run();

?>

Note

For a full documentations of Eloquent see http://laravel.com/docs/5.1/eloquent, (*2)

The Versions

30/11 2015

dev-master

9999999-dev http://github.com/overflowsith/slim-eloquent

Use Eloquent ORM in Slim 3

  Sources   Download

MIT

The Requires

 

orm database framework eloquent slim

30/11 2015

0.1.0

0.1.0.0 http://github.com/overflowsith/slim-eloquent

Use Eloquent ORM in Slim 3

  Sources   Download

MIT

The Requires

 

orm database framework eloquent slim