Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Widget hooks are not working in Elementor. #5844

Closed
5 tasks done
hectorfarahani opened this issue Oct 3, 2018 · 2 comments
Closed
5 tasks done

Widget hooks are not working in Elementor. #5844

hectorfarahani opened this issue Oct 3, 2018 · 2 comments
Labels
status/merged Indicates when a Pull Request has been merged to a Release.
Milestone

Comments

@hectorfarahani
Copy link

hectorfarahani commented Oct 3, 2018

Prerequisites

  • I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
  • The issue still exists against the latest stable version of Elementor.

Description

Many users are using in_widget_form and widget_update_callback hooks to add custom fields to widgets.
Seems that Elementor doesn't calls these hooks at all. There is no visible custom markup in widget form while using widgets from Elementor and it shows only default widget fields.

Also there is some plugins that are using these hooks to extend widgets functionality. (e.g. Advanced Custom Fields) and these hooks are necessary for them.

Steps to reproduce

Use the following code to add something in widgets. It works in Appearance-> Widgets, But not in Elementor-> WordPress Widgets.

add_action('in_widget_form', 'issue_in_widget_form' );

function issue_in_widget_form( $instance ){
    echo 'This should be visible in Elementor too.';
    return $instance;
}

Isolating the problem

  • This bug happens with only Elementor plugin active (and Elementor Pro).
  • This bug happens with a default WordPress theme active.
  • I can reproduce this bug consistently using the steps above.
bainternet added a commit to bainternet/elementor that referenced this issue Oct 4, 2018
@bainternet bainternet added the status/has-pr Indicates that an Issue, or Discussion has a companion Pull Request awaiting to be merged. label Oct 4, 2018
@bainternet
Copy link
Contributor

@h71

Thanks for reporting.

KingYes added a commit that referenced this issue Oct 4, 2018
Fix: WP Widget hooks support closes #5844
@bainternet bainternet added status/merged Indicates when a Pull Request has been merged to a Release. and removed status/has-pr Indicates that an Issue, or Discussion has a companion Pull Request awaiting to be merged. labels Oct 4, 2018
@bainternet bainternet added this to the 2.3.0 milestone Oct 4, 2018
@MartinStehle
Copy link

MartinStehle commented Jan 9, 2019

Hi, I offer a plugin which adds some options to any widget via the hooks in_widget_form. Elementor uses this hook, too. The extra options are displayed in the editor. But saving their settings failes since the hook widget_update_callback is not integrated in Elementor.

Is it possible to add the missing hook in Elementor? Are the hooks also integrated into Elementor Pro?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/merged Indicates when a Pull Request has been merged to a Release.
Projects
None yet
Development

No branches or pull requests

3 participants