verygoodplugins

Untitled

Jan 25th, 2021
427
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.         $element->add_control(
  2.             'wpf_visibility',
  3.             [
  4.                 'label'       => __( 'Visibility', 'wp-fusion' ),
  5.                 'type'        => \Elementor\Controls_Manager::SELECT,
  6.                 'default'     => 'everyone',
  7.                 'options'     => array(
  8.                     'everyone'  => __( 'Everyone', 'wp-fusion' ),
  9.                     'loggedin'  => __( 'Logged In Users', 'wp-fusion' ),
  10.                     'loggedout' => __( 'Logged Out Users', 'wp-fusion' ),
  11.                 ),
  12.                 'multiple'    => false,
  13.                 'label_block' => true,
  14.             ]
  15.         );
  16.  
  17.         $element->add_control(
  18.             'wpf_tags',
  19.             [
  20.                 'label'       => sprintf( __( 'Required %s Tags (Any)', 'wp-fusion' ), wp_fusion()->crm->name ),
  21.                 'type'        => \Elementor\Controls_Manager::SELECT2,
  22.                 'options'     => $data,
  23.                 'multiple'    => true,
  24.                 'label_block' => true,
  25.                 'condition'   => array(
  26.                     'wpf_visibility' => [ 'loggedin', 'everyone' ],
  27.                 ),
  28.                 //'description' => __( 'The user must be logged in and have at least one of the tags specified to access the content.', 'wp-fusion' ),
  29.             ]
  30.         );
  31.  
  32.         $element->add_control(
  33.             'wpf_tags_all',
  34.             [
  35.                 'label'       => sprintf( __( 'Required %s Tags (All)', 'wp-fusion' ), wp_fusion()->crm->name ),
  36.                 'type'        => \Elementor\Controls_Manager::SELECT2,
  37.                 'options'     => $data,
  38.                 'multiple'    => true,
  39.                 'label_block' => true,
  40.                 'condition'   => array(
  41.                     'wpf_visibility' => [ 'loggedin', 'everyone' ],
  42.                 ),
  43.                 //'description' => __( 'The user must be logged in and have <em>all</em> of the tags specified to access the content.', 'wp-fusion' ),
  44.             ]
  45.         );
  46.  
  47.         $element->add_control(
  48.             'wpf_tags_not',
  49.             [
  50.                 'label'       => sprintf( __( 'Required %s Tags (Not)', 'wp-fusion' ), wp_fusion()->crm->name ),
  51.                 'type'        => \Elementor\Controls_Manager::SELECT2,
  52.                 'options'     => $data,
  53.                 'multiple'    => true,
  54.                 'label_block' => true,
  55.                 'condition'   => array(
  56.                     'wpf_visibility' => [ 'everyone', 'loggedin' ],
  57.                 ),
  58.                 'description' => __( 'If the user is logged in and has any of these tags, the content will be hidden.', 'wp-fusion' ),
  59.             ]
  60.         );
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×