Flaming-Crud: Another CRUD Generator |
[eluser]clip[/eluser]
Firstly I would like to thank dixcoder for the inspiration from his Model/Controller Generator I had also been contemplating throwing something like this together and now that I have done it, I wish I would have done it along time ago. The focus of Flaming-Crud is currently on models only. I have created and successfully used two different models with it now without issue. These were done on my local environment but I don't see why it would work on your host. Here is a quick run down: Quote:Download and unzip the ci_crud.php file and upload to your server. Model Structure: The generated model will have a property created for each field from the db table along with $limit, $offset, and $order_by properties. Code: public $id; //in this example $id is the primary key from our table. Usage: Code: class Some_controller extends Controller Enjoy! Would love to here any feedback anyone may have. Edit: I have made a minor change to how the code is output for returning query->result() and query->row(). Before this change a return of query->result() may have been expected but query->row() was returned instead. |
Messages In This Thread |
Flaming-Crud: Another CRUD Generator - by El Forum - 10-29-2009, 11:38 PM
Flaming-Crud: Another CRUD Generator - by El Forum - 10-30-2009, 04:12 AM
Flaming-Crud: Another CRUD Generator - by El Forum - 10-30-2009, 09:21 PM
Flaming-Crud: Another CRUD Generator - by El Forum - 11-01-2009, 10:25 PM
Flaming-Crud: Another CRUD Generator - by El Forum - 11-03-2009, 07:20 PM
Flaming-Crud: Another CRUD Generator - by El Forum - 11-05-2009, 02:09 PM
Flaming-Crud: Another CRUD Generator - by El Forum - 11-11-2009, 07:09 PM
|