Support » Plugin: Widgets on Pages » Warning: call_user_func_array() expects parameter 1 to be a valid callback,

  • Resolved WebDragon

    (@webdragon)


    Warning: call_user_func_array() expects parameter 1 to be a valid callback, first array member is not a valid class name or object in wp-includes/class-wp-hook.php on line 300

    warning appears when viewing a Page in the admin side editor, and Problem appears/disappears when activating/deactivating your plugin

    Unfortunately we’re using it fairly extensively, so removing it isn’t much of an option. Will do what I can to help debug the issue.

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Oh thanks for the info… I don’t think I’ve seen this before… and having a quick look it seems to be related to the Freemius libs I use in the plugin. I’ll do some digging and should hopefully be able to get you an update.

    If it helps in tracking it down, the error only shows up when viewing an existing, published Page/Post but not when you are generating a New one.

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Brilliant, thanks for the extra info.

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Hi @webdragon, do you know at what version this started being an issue for you, and if it recently started do you know what version you were running before.

    Also could you provide the following please;
    * WordPress Version
    * Theme
    * PHP Version – if possible, could be to do with PHP 5.4 and below

    Thanks,
    Todd

    The server is on 5.3.29 if that’s any help (Stuck there for the time being but we hope to get migrated to a newer server soon)

    WordPress version is 4.8.1 and the theme is irrelevant; I’m using a custom theme based on roots.io/Sage but I get the same thing if I switch to twentyseventeen.

    I think the problem may have been masked by the fact that during development, we were using the Query Monitor plugin (along with some others) for testing purposes, and the warning would have been brought up into Query Monitor’s list rather than as blatantly displayed as it is without that. So, as a result, I don’t know quite when it started.

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Thanks for the extra info @webdragon, I really appreciate it.

    From my initial digging it looks like it could be the PHP version. I have some dev environments setup running earlier versions, so I’ll have a run out there and will update you.

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Good news @webdragon, I have (I believe) pinpointed the issue, thanks to your info… and it does seem to be a conflict with pre-PHP4.

    I’m working on a fix at the mo, and it seems to be working just fine.
    I will need to do some further testing though before an update comes out.
    I have a v1.3.0 lined up with some other minor changes, so I’ll see if I can get this into that build too.

    Thanks again for raising the issue and providing the derails.
    Todd

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Hi @webdagon,

    Just a quick heads up… this is passing all my tests now, and I’ve pushed the fix to the Widgets on Pages PRO version. The update will get pushed to the wp.org repo tomorrow, I think.

    When you get the update I’d very much appreciate it if you could let me know if this has fixed the issue for you. The update will be version v1.3.0

    Ta, Todd

    I’ll look for the update and let you know whether the problem has been fully caught. Appreciate the heads-up.

    Cheers,

    Scott

    Just a quick note, on the update changelog: I think you meant to say PHP5.4 not PHP4 😉

    And yes, I can confirm the issue is solved.

    Plugin Author toddhalfpenny

    (@toddhalfpenny)

    Ha ha ha, yes… good spot… thanks @webdragon.
    And great to hear this update fixes you issue, cheers for supplying the details.

    Ta, Todd

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Warning: call_user_func_array() expects parameter 1 to be a valid callback,’ is closed to new replies.