FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » What could be causing this "Invalid callback" warning?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: What could be causing this "Invalid callback" warning? [message #170926 is a reply to message #170914] Wed, 08 December 2010 22:32 Go to previous message
Jerry Stuckle is currently offline  Jerry Stuckle
Messages: 2598
Registered: September 2010
Karma:
Senior Member
On 12/8/2010 12:11 AM, Roy Smith wrote:
> On Dec 7, 11:08 pm, Jerry Stuckle<jstuck...@attglobal.net> wrote:
>> No, that's for a STATIC function. You are not calling a static member
>> of the class, so an object is required (which is what your message is
>> telling you).
>
> Um, is there some specific reason you think
> Amie_ResponseHandler::errorHandler() is not static? It's declared:
>
> public static function errorHandler($severity,$msg,$filename,
> $linenum) {
> ... }
>

Sorry, I should have read the message more closely. I shouldn't try to
do this when I'm tired :)

Are you sure the class is being loaded? Just using the class name as a
string in the set_error_handler() call doesn't necessarily check that
the class exists at that time.

What happens if you specifically load the class with require_once()
before calling set_error_handler()? Or what happens if you do a

$hdlr = new Amnie_ResponseHandler();

before registering the class?

I don't use the PEAR HTTP_Request class; it's way back level (as you
found), and everything in the class is available anyway. Just never
found a need for it. So I can't say how it works when you're loading
that code.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex(at)attglobal(dot)net
==================
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Try to write php code for this ..
Next Topic: Session Handling for multiple languages, permission denied
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Sep 27 21:21:24 GMT 2024

Total time taken to generate the page: 0.05979 seconds