[eluser]fritzthecat[/eluser]
Hi. I need to pass the results of a subroutine to a function that expects a query object, and on occasions I need to create an empty db query object - something like
Code:
function getStuff( $id=false ) {
if( !$id ) {
return $this->db->query();
} else {
return $this->db->get_where( 'stuff', "id=$id" );
}
how would you do it?
thanks