2017 © Pedro Peláez
 

library activerecord

Activerecord is a revised implementation of php-Activerecord by jpfuent an open source ORM library based on the Activerecord pattern.

image

wriver4/activerecord

Activerecord is a revised implementation of php-Activerecord by jpfuent an open source ORM library based on the Activerecord pattern.

  • Thursday, June 23, 2016
  • by wriver4
  • Repository
  • 1 Watchers
  • 1 Stars
  • 20 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

Activerecord

Warning working on conforming to PSR-1 starting 5/11/2016 use Ver. 1.1, (*1)

Instructions

Uses Composer to manage autoload. In bootstrap file assuming root directory., (*2)

$loader = require_once 'vendor/autoload.php';
$loader->addPsr4('Models\\', __dir__.'\Models');
// What? Why? Composers base path is vendor and I don't want to update Composer for every new Model.

//Simple Config
$cfg = Activerecord\Config::instance();
$cfg->setConnections(array(
    'development' =>
    'mysql://root:root@localhost/treebark?charset=utf8'));

Model classes, (*3)

namespace Models;

class Bar \\ for table name bars by convention
        extends \Activerecord\Model \\ leading slash required
{
}

Super Simple Usage Example:, (*4)

$bars = Models\Bar::find(1)->to_array();
echo $bars['name'];
echo '<br>';
$bars = Models\Bar::all();
foreach ($bars as $bar)
{
    echo '<br> id:';
    echo $bar->id;
    echo '<br> Name of Bar:';
    echo $bar->name;
    echo '<br> Address:';
    echo $bar->address;
    echo '<br>';
}

The php-Activerecord.org instructions for use remain the same., (*5)

Updated 4/25/2016

A revised implementation of php-Activerecord by jpfuentes; Currently working but testing system incomplete., (*6)

Original Commit 12/9/2015

A revised implementation of php-Activerecord by jpfuentes This is an inprocess version testing is not complete. So far the php-Activerecord.org instructions for use remain the same., (*7)

The Versions

23/06 2016

dev-master

9999999-dev http://www.whizbangdevelopers.com/

Activerecord is a revised implementation of php-Activerecord by jpfuent an open source ORM library based on the Activerecord pattern.

  Sources   Download

MIT

orm activerecord

09/06 2016

2.0.0

2.0.0.0 http://www.whizbangdevelopers.com/

Activerecord is a revised implementation of php-Activerecord by jpfuent an open source ORM library based on the Activerecord pattern.

  Sources   Download

MIT

orm activerecord

26/05 2016

dev-testing

dev-testing http://www.whizbangdevelopers.com/

Activerecord is a revised implementation of php-Activerecord by jpfuent an open source ORM library based on the Activerecord pattern.

  Sources   Download

MIT

orm activerecord

06/05 2016

1.1.0

1.1.0.0 http://www.whizbangdevelopers.com/

activerecord is a revised implementation of php-activerecord by jpfuent an open source ORM library based on the ActiveRecord pattern.

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

orm activerecord