Forums

Page Meta
Errors on activation and deactivation (2 posts)

  1. wpsecuritylock
    Member
    Posted 6 months ago #

    I copied this from a previous reply I posted on the forum and realized I should put it here since this plugin appears to be broken.

    The plugin generated 278 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.

    When I deactivate it, I get this error (but it flashes really fast):

    Warning: call_user_func_array()[function.call-user-func-array]: First argument is expected to be a valid callback, 'Array' was giving in /wp-includes/plugin.php on line 405.

    Any ideas?

    http://wordpress.org/extend/plugins/pagemeta/

  2. johnmdmnsys
    Member
    Posted 5 months ago #

    I found the source of the activation error and am looking for the most appropriate place to post about it. (This is my first plugin bug find!)

    Inside the pagemeta folder, in the file index.php lines 29-30 show the following:

    register_activation_hook(__FILE__, array(&$pageMeta, 'activate'));
    register_deactivation_hook(__FILE__, array(&$pageMeta, 'deactivate'));

    Change both of the '$pageMeta' variables to '$this':

    register_activation_hook(__FILE__, array(&$this, 'activate'));
    register_deactivation_hook(__FILE__, array(&$this, 'deactivate'));

    After this change I no longer get the warning message on activation.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags