Welcome Guest, Not a member yet? Register   Sign In
CRUD with Ci 1.7
#7

[eluser]pistolPete[/eluser]
@umefarooq: Some suggestions:

If you want to use the class in PHP4, there is a problem with calling get_instance() from within the class constructors.
Have a look at:
- Utilizing CodeIgniter Resources within Your Library
- Bug Report

I'd rather use NULL as the default value of some parameters as it is NULL as well in the CI_DB_active_record class; e.g.:
Code:
function getRecords($table, $num = NULL, $offset = NULL)

Add an instance variable $table to the class and pass it to the constructor and / or provide a method setTable($tableName), so you don't have to pass the table name everytime you want to call a single function.


Messages In This Thread
CRUD with Ci 1.7 - by El Forum - 01-29-2009, 07:35 PM
CRUD with Ci 1.7 - by El Forum - 01-30-2009, 01:15 AM
CRUD with Ci 1.7 - by El Forum - 01-30-2009, 05:21 AM
CRUD with Ci 1.7 - by El Forum - 02-11-2009, 07:56 PM
CRUD with Ci 1.7 - by El Forum - 02-12-2009, 12:35 AM
CRUD with Ci 1.7 - by El Forum - 02-13-2009, 02:15 AM
CRUD with Ci 1.7 - by El Forum - 02-13-2009, 02:55 AM
CRUD with Ci 1.7 - by El Forum - 02-13-2009, 11:32 AM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 04:46 AM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 04:58 AM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 11:27 AM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 12:00 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 12:51 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 12:59 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 01:02 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 01:06 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 01:14 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 01:45 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 02:55 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 02:58 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 03:06 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 03:09 PM
CRUD with Ci 1.7 - by El Forum - 02-14-2009, 04:52 PM
CRUD with Ci 1.7 - by El Forum - 02-24-2009, 08:45 AM



Theme © iAndrew 2016 - Forum software by © MyBB