[resolved] ERROR! when installing plugins (4 posts)

  1. bobbingwide
    Posted 3 years ago #

    On my local (Windows) machine I run multiple instances of WordPress in both root and subdirectory installs. When I attempt to Install or Activate a plugin from the popup dialog of the Settings page the result is shown as Error!
    On refresh of the display the correct result is shown.

    Two things.
    1. Please help me to analyse the problem.
    2. You have to do a lot better with error reporting than "Error!"


  2. Alex Mills (Viper007Bond)
    Plugin Author

    Posted 3 years ago #

    I've pushed a change to the development version of the plugin that will make an alert box pop up with a much more descriptive error message if there was a problem with installing or activating a plugin.

    You can snag an alpha version of the plugin containing that change here: https://github.com/Automattic/developer/zipball/master

  3. bobbingwide
    Posted 3 years ago #

    OK Alex thanks. I discovered that the first problem was caused by an error in my own code. It was producing a Warning message during plugin_activate; because my function was missing.

    I reproduced it to test your changes and got some interesting results.

    When my plugin's code included:
    add_action( "activate_plugin", "oik_activate_plugin_action_missing" );

    I got these messages:

    Activate -> Fatal error: Call to undefined function get_error_message() at line 375.

    Install -> undefined get_error_message() at 343 / 379
    or simply -1

    get_error_message() is a method not a function.

    When my filter function did exist but didn't Fatal e.g. just echo'ed
    a string OR otherwise produced a Warning then I didn't get any message.
    Not even the (rather useless, in my opinion) message "The plugin generated 202 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."

    BTW. The modal message box was REALLY annoying.

    PS. I believe you've got the wrong plugin name for piglatin
    PPS. I suggest someone updates piglatin to remove the "old plugin" message.

  4. Mohammad Jangda
    Plugin Author

    Posted 3 years ago #

    Thanks for pointing out the piglatin issue, @bobbingwide. We've pushed a fix in v1.1.1.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Developer
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic