Welcome Guest, Not a member yet? Register   Sign In
Undefined valuable
#2

(This post was last modified: 05-09-2017, 01:10 AM by neuron.)

in get_school method you are returning object of row objects, you need to fetch only one row. 
update your method:
PHP Code:
public function get_school() {
 
  $query $this->db->query("SELECT sname FROM setting");
if(
$query){
 return 
$query->row();
}
 
 return false//or return empty array


use print_r or var_dump functions for debugging your code
Reply


Messages In This Thread
Undefined valuable - by kayinja.denis - 05-09-2017, 12:54 AM
RE: Undefined valuable - by neuron - 05-09-2017, 01:07 AM
RE: Undefined valuable - by kayinja.denis - 05-11-2017, 06:29 AM
RE: Undefined valuable - by php_rocs - 05-09-2017, 08:13 AM
RE: Undefined valuable - by neuron - 05-10-2017, 02:41 AM
RE: Undefined valuable - by kayinja.denis - 05-10-2017, 03:30 AM
RE: Undefined valuable - by neuron - 05-11-2017, 06:48 AM
RE: Undefined valuable - by InsiteFX - 05-10-2017, 03:48 AM
RE: Undefined valuable - by kayinja.denis - 05-10-2017, 04:17 AM
RE: Undefined valuable - by mirivlad - 05-10-2017, 08:08 AM
RE: Undefined valuable - by InsiteFX - 05-10-2017, 12:06 PM
RE: Undefined valuable - by kayinja.denis - 05-11-2017, 04:28 AM
RE: Undefined valuable - by InsiteFX - 05-11-2017, 09:14 AM
RE: Undefined valuable - by xenomorph1030 - 05-11-2017, 08:17 AM
RE: Undefined valuable - by kayinja.denis - 05-11-2017, 10:21 PM



Theme © iAndrew 2016 - Forum software by © MyBB