Last active
August 24, 2024 08:18
-
-
Save lunule/dfcf25f3459bcdc8d43267041169faa1 to your computer and use it in GitHub Desktop.
[WordPress - Elementor | Check if specific Elementor widget is loaded/used] #wp #elementor #widget #shortcode
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
<?php | |
global $post; | |
if ( is_a($post, 'WP_Post') ) : | |
$post_id = $post->ID; | |
$elementor_data = get_post_meta($post_id, '_elementor_controls_usage', true); | |
$has_fl_map = array_key_exists('fl-map', $elementor_data); | |
// (...) | |
endif; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment