Hi there. I've searched everywhere and can't seem to find the answer to this. Does anyone know if it's possible to reference a method in a Class without having to instantiate it? I know this is possible in other OOP languages.
eg.
Class Foo
{
function foobar(param)
{
do stuff
return something
}
}
Now can I make a call to foobar directly from outside code?
$Foo->foobar("bob") simply gives the old "call to member function on non-object" error msg. If this was Java, I could do call: Foo.foobar("bob") no prob. Is this functionality in PHP or no? Just curious. Thanks!