-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tweak! - Added compatibility for NextGen gallery plugin
- Loading branch information
Showing
3 changed files
with
24 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
namespace Elementor; | ||
|
||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly | ||
|
||
class Compatibility { | ||
|
||
public static function register_actions() { | ||
add_action( 'init', [ __CLASS__, 'init' ] ); | ||
} | ||
|
||
public static function init() { | ||
// Hotfix for NextGEN Gallery plugin | ||
if ( defined( 'NGG_PLUGIN_VERSION' ) ) { | ||
add_filter( 'elementor/utils/get_edit_link', function( $edit_link ) { | ||
return add_query_arg( 'display_gallery_iframe', '', $edit_link ); | ||
} ); | ||
} | ||
} | ||
} | ||
|
||
Compatibility::register_actions(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters