Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Advanced_Coupons_Helpers::get_options_for_credit( $label = null, $option_code = 'PPCONDITION', $args = array() )
Get drop down options for the conditions.
Contents
Warning: Array to string conversion in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 825
Warning: foreach() argument must be of type array|object, string given in /home/customer/www/docs.automatorplugin.com/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 830
Parameters Parameters
(Required) peepso users
Source Source
File: src/integrations/advanced-coupons/helpers/advanced-coupons-helpers.php
public function get_options_for_credit( $label = null, $option_code = 'PPCONDITION', $args = array() ) { if ( ! $label ) { $label = esc_attr__( 'Select condition', 'uncanny-automator' ); } $args = wp_parse_args( $args, array( 'uo_include_any' => false, 'uo_any_label' => esc_attr__( 'Any condition', 'uncanny-automator' ), ) ); $options = array(); if ( $args['uo_include_any'] ) { $options['-1'] = $args['uo_any_label']; } $options['EQ'] = __( 'equal to', 'uncanny-automator' ); $options['NOT_EQ'] = __( 'not equal to', 'uncanny-automator' ); $options['LT'] = __( 'less than', 'uncanny-automator' ); $options['GT'] = __( 'greater than', 'uncanny-automator' ); $options['GT_EQ'] = __( 'greater or equal to', 'uncanny-automator' ); $options['LT_EQ'] = __( 'less or equal to', 'uncanny-automator' ); $option = array( 'option_code' => $option_code, 'label' => $label, 'input_type' => 'select', 'required' => true, 'options' => $options, 'relevant_tokens' => array(), ); return apply_filters( 'uap_option_advanced_coupons_all_conditions', $option ); }
Expand full source code Collapse full source code View on Github