WP Page Widget
[resolved] Generic fix for Image Widget type problems (3 posts)

  1. rbottomley
    Posted 2 years ago #

    I have a widget that was having the same issues as Image Widget once was: code that was attached to sidebar_admin_setup action was not firing when using the widget in a page, but would work fine on the global widgets. Around line 1286 of wp-page-widgets.php I see hardcoded code to fix Image Widget. But what about any other widgets that need this action?

    Instead of the code for Image Widget, how about doing:


    This fixed my widget. Is there a reason not to call do_action? If there is no downside, this generic fix would work for any widget the requires the sidebar_admin_setup action.


  2. rbottomley
    Posted 2 years ago #

    When I said "line 1286", I was looking at the wrong thing. That should be "line 107". Sorry.

  3. CodeAndMore
    Plugin Author

    Posted 2 years ago #

    That line is open for all widgets now so consider solved.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Page Widget
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic