Welcome Guest, Not a member yet? Register   Sign In
Model error
#1

[eluser]barak[/eluser]
Hi,
I have a problem loading a model.
This is how its start:

Code:
function show()
    {
        parent::Model();
        $query = $this->db->query(" SELECT *FROM `army`  WHERE `id` = '1' ")or die("error reading id");

The error is on the query line.
This is the error:
Code:
Fatal error: Call to a member function query() on a non-object in C:\wamp\www\arena\system\application\models\s_train.php on line 12

Last time I had this error because I forget to parent the function.
But now I do have this line.

Thank you.


Messages In This Thread
Model error - by El Forum - 05-24-2009, 06:17 AM
Model error - by El Forum - 05-24-2009, 06:31 AM
Model error - by El Forum - 05-24-2009, 07:24 AM
Model error - by El Forum - 05-24-2009, 07:59 AM
Model error - by El Forum - 05-24-2009, 08:01 AM



Theme © iAndrew 2016 - Forum software by © MyBB