Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Log - Non-static method *** should not be called statically
  • My log is flooded with log entries like in the title
    Non-static method *** should not be called statically

    Although I don't get any errors on the web pages itself, they do appear in my log. An example where that happens is:
    if(Model_Character::is_owned($this->user_id, $character_id))
    {
    
    }
    

    It might be something simple and beginners mistake, but I do suggest to others to check their logs :D
  • If you call a method statically (class::method) you have to declare the method as static:
    class Class
    { 
        public [b]static[/b] function method
        {
        }
    }
    
  • thanks :)

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion