Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function wpf_elementor_can_access( $can_access, $element ) {
- $widget_tags = $element->get_settings( 'wpf_tags' );
- if ( ! empty( $widget_tags ) && in_array( 'DYNAMIC', $widget_tags ) ) {
- $can_access = false;
- global $post;
- if ( wp_fusion()->user->has_tag( 'Listing - ' . $post->ID ) ) {
- $can_access = true;
- }
- }
- return $can_access;
- }
- add_filter( 'wpf_elementor_can_access', 'wpf_elementor_can_access', 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement