Super Simple Object Relational Mapper - SSORM PDF  | Print |  E-mail
Written by Andrew Drane   
Thursday, 19 March 2009 14:52

SSORM - Super Simple Object Relational Mapper for PHP

This is a quick way to make an object relational mapper for PHP using some design patterns similar to Active Record in Rails. It creates an easy-to-use and setup environment to add, edit and relate objects in an MVC environment. You can also easily import your models to existing pages, how easy is that! Sure, there are much more robust applications out there, like Cake PHP, but this is meant for quick little projects where you don't want to deal with installing anything!

I am still struggling with some of the static PHP methods, but A quick example of what it looks like now

$p = new Product.


 foreach( $producs as $product ){


There is a lot to do on this, please feel free to add to this list!

  1. Make better static "find" methods, perhaps something like find("product", {conditions});
  2. Improve the find_by to integrate more powerful associative array based conditions
  3. Better integration of migrations, separate out all functionality from that file.
  4. Documentation!
Last Updated on Thursday, 19 March 2009 15:36
Copyright © 2019 Andrew Drane. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.