Welcome Guest, Not a member yet? Register   Sign In
accessing data in a controller
#4

[eluser]jedd[/eluser]
You appear to be having an error in the one file that you did not post.

How strange.

Anyhoo, in your model, test for ->num_rows rather than just testing ($result) ... it'll make you happier.

If you want to return 0 on failure, then you need to test (later) that you have an object to talk to, and not assume it's an object (because at the moment it's 0 .. which isn't very objecty).


Messages In This Thread
accessing data in a controller - by El Forum - 09-02-2009, 04:13 AM
accessing data in a controller - by El Forum - 09-02-2009, 04:26 AM
accessing data in a controller - by El Forum - 09-02-2009, 06:56 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:05 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:10 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:13 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:20 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:22 AM
accessing data in a controller - by El Forum - 09-02-2009, 07:40 AM



Theme © iAndrew 2016 - Forum software by © MyBB