problem in form_validation using is_callable(), cannot passing data from controller |
(04-15-2019, 09:49 PM)DELE Wrote: why does it not return object values? instead returns a null value? and how do I overcome that using the is_callable() method? It returns no object because no record in the database satisfied the where condition. In other words, there is no data to turn into an object. Perhaps the easiest solution is to have the callback respond in a logical way when its argument is null. Oh... and for what it's worth. The following PHP Code: public function check_role($email){ would be much more concise if written like this PHP Code: public function check_role($email){ Or, if you want to account for the argument possibly being null PHP Code: public function check_role($email){ |
Messages In This Thread |
problem in form_validation using is_callable(), cannot passing data from controller - by DELE - 04-15-2019, 07:00 PM
RE: problem in form_validation using is_callable() - by dave friend - 04-15-2019, 07:15 PM
RE: problem in form_validation using is_callable() - by DELE - 04-15-2019, 07:40 PM
RE: problem in form_validation using is_callable() - by dave friend - 04-15-2019, 08:10 PM
RE: problem in form_validation using is_callable() - by DELE - 04-15-2019, 09:49 PM
RE: problem in form_validation using is_callable() - by dave friend - 04-16-2019, 08:21 AM
RE: problem in form_validation using is_callable() - by DELE - 04-16-2019, 09:11 AM
|