当前位置: 首页>>代码示例>>PHP>>正文


PHP WC_Admin_Settings::output_fields方法代码示例

本文整理汇总了PHP中WC_Admin_Settings::output_fields方法的典型用法代码示例。如果您正苦于以下问题:PHP WC_Admin_Settings::output_fields方法的具体用法?PHP WC_Admin_Settings::output_fields怎么用?PHP WC_Admin_Settings::output_fields使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WC_Admin_Settings的用法示例。


在下文中一共展示了WC_Admin_Settings::output_fields方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: woocommerce_admin_fields

/**
 * Output admin fields.
 *
 * Loops though the woocommerce options array and outputs each field.
 *
 * @param array $options Opens array to output
 */
function woocommerce_admin_fields($options)
{
    if (!class_exists('WC_Admin_Settings')) {
        include 'class-wc-admin-settings.php';
    }
    WC_Admin_Settings::output_fields($options);
}
开发者ID:hoonio,项目名称:PhoneAfrika,代码行数:14,代码来源:wc-admin-functions.php

示例2: output

 /**
  * Output the settings.
  */
 public function output()
 {
     global $current_section, $hide_save_button;
     // Load shipping methods so we can show any global options they may have
     $shipping_methods = WC()->shipping->load_shipping_methods();
     if ('options' === $current_section) {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
         return;
     } elseif ('classes' === $current_section) {
         $hide_save_button = true;
         $this->output_shipping_class_screen();
         return;
     } else {
         foreach ($shipping_methods as $method) {
             if (strtolower(get_class($method)) === strtolower($current_section) && $method->has_settings()) {
                 $method->admin_options();
                 return;
             }
         }
     }
     // Default to zones screen
     $hide_save_button = true;
     $this->output_zones_screen();
 }
开发者ID:KristoferN,项目名称:woocommerce,代码行数:28,代码来源:class-wc-settings-shipping.php

示例3: output

        /**
         * Output the settings.
         *
         * @since 1.0.0
         */
        public function output() {

            global $current_section;

            $settings = $this->get_settings( $current_section );
            WC_Admin_Settings::output_fields( $settings );

        }
开发者ID:helloworld-digital,项目名称:katemorgan,代码行数:13,代码来源:class-wwp-settings.php

示例4: output_settings_fields

 public function output_settings_fields()
 {
     WC_Admin_Settings::output_fields($this->settings);
     $jsPath = $this->options->get_react_app_path();
     echo $this->batch_upload();
     $data = array('apiUrl' => plugins_url('api.php', dirname(__FILE__)));
     wp_enqueue_script('wc-siftsci-react-app', $jsPath, array(), false, true);
     wp_localize_script('wc-siftsci-react-app', "_siftsci_app_input_data", $data);
 }
开发者ID:Fermiac,项目名称:woocommerce-siftscience,代码行数:9,代码来源:class-wc-siftscience-hooks-admin.php

示例5: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     if ($current_section == '') {
         $GLOBALS['hide_save_button'] = true;
     }
     $settings = $this->get_settings($current_section);
     WC_Admin_Settings::output_fields($settings);
     $this->show_table_products();
 }
开发者ID:WP-Panda,项目名称:m.video,代码行数:13,代码来源:class-settings-products.php

示例6: output_settings

 public function output_settings()
 {
     global $current_section;
     $settings = $this->get_settings($current_section);
     $hide_sec = array('plugin', 'newsletter');
     if (in_array($current_section, $hide_sec)) {
         $GLOBALS['hide_save_button'] = true;
     } else {
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:7GRAFIX,项目名称:WooCommerce-Role-Based-Price,代码行数:11,代码来源:class-admin-settings.php

示例7: output

 /**
  * Render the settings for the current section
  *
  * @since 2.0.0
  */
 public function output()
 {
     $settings = $this->get_settings();
     // inject the actual setting value before outputting the fields
     // ::output_fields() uses get_option() but customizations are stored
     // in a single option so this dynamically returns the correct value
     foreach ($this->customizations as $filter => $value) {
         add_filter("pre_option_{$filter}", array($this, 'get_customization'));
     }
     WC_Admin_Settings::output_fields($settings);
 }
开发者ID:yarwalker,项目名称:ecobyt,代码行数:16,代码来源:class-wc-customizer-settings.php

示例8: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     $tax_classes = array_filter(array_map('trim', explode("\n", get_option('woocommerce_tax_classes'))));
     if ($current_section == 'standard' || in_array($current_section, array_map('sanitize_title', $tax_classes))) {
         $this->output_tax_rates();
     } else {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:joshquila,项目名称:demo2-youse,代码行数:14,代码来源:class-wc-settings-tax.php

示例9: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     $tax_classes = WC_Tax::get_tax_classes();
     if ($current_section == 'standard' || in_array($current_section, array_map('sanitize_title', $tax_classes))) {
         $this->output_tax_rates();
     } else {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:ayoayco,项目名称:upbeat,代码行数:14,代码来源:class-wc-settings-tax.php

示例10: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     $settings = $this->get_settings();
     WC_Admin_Settings::output_fields($settings);
     if ($current_section == 'lists') {
         include_once MailPoet_WooCommerce_Add_on()->plugin_path() . '/includes/admin/settings/settings-newsletters.php';
         $mailpoet_list = mailpoet_lists();
         do_action('woocommerce_mailpoet_list_newsletters', $mailpoet_list);
     }
 }
开发者ID:alikagitci,项目名称:honda.yedekleri,代码行数:14,代码来源:class-mailpoet-woocommerce-settings.php

示例11: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     if ($current_section == '') {
         $settings = $this->rf_genaral_setting();
     } elseif ($current_section == 'email_template') {
         $settings = $this->rf_email_template_setting();
     } else {
         $settings = $this->rf_social_share_setting();
     }
     WC_Admin_Settings::output_fields($settings);
 }
开发者ID:javolero,项目名称:dabba,代码行数:15,代码来源:referfriend-settings.php

示例12: output

 /**
  * Output the settings.
  */
 public function output()
 {
     global $current_section;
     // Load shipping methods so we can show any global options they may have.
     $payment_gateways = WC()->payment_gateways->payment_gateways();
     if ($current_section) {
         foreach ($payment_gateways as $gateway) {
             if (in_array($current_section, array($gateway->id, sanitize_title(get_class($gateway))))) {
                 $gateway->admin_options();
                 break;
             }
         }
     } else {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:woocommerce,项目名称:woocommerce,代码行数:20,代码来源:class-wc-settings-checkout.php

示例13: output

 /**
  * Output the settings
  */
 public function output()
 {
     global $current_section;
     // Load shipping methods so we can show any global options they may have
     $shipping_methods = WC()->shipping->load_shipping_methods();
     if ($current_section) {
         foreach ($shipping_methods as $method) {
             if (strtolower(get_class($method)) == strtolower($current_section) && $method->has_settings()) {
                 $method->admin_options();
                 break;
             }
         }
     } else {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:joshquila,项目名称:demo2-youse,代码行数:20,代码来源:class-wc-settings-shipping.php

示例14: output

 /**
  * Output the settings.
  */
 public function output()
 {
     global $current_section;
     // Define emails that can be customised here
     $mailer = WC()->mailer();
     $email_templates = $mailer->get_emails();
     if ($current_section) {
         foreach ($email_templates as $email_key => $email) {
             if (strtolower($email_key) == $current_section) {
                 $email->admin_options();
                 break;
             }
         }
     } else {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     }
 }
开发者ID:tlovett1,项目名称:woocommerce,代码行数:21,代码来源:class-wc-settings-emails.php

示例15: output

 /**
  * Output the settings.
  */
 public function output()
 {
     global $current_section, $hide_save_button;
     // Load shipping methods so we can show any global options they may have
     $shipping_methods = WC()->shipping->load_shipping_methods();
     if ('' === $current_section) {
         $this->output_zones_screen();
     } elseif ('options' === $current_section) {
         $settings = $this->get_settings();
         WC_Admin_Settings::output_fields($settings);
     } elseif ('classes' === $current_section) {
         $hide_save_button = true;
         $this->output_shipping_class_screen();
     } else {
         foreach ($shipping_methods as $method) {
             if (in_array($current_section, array($method->id, sanitize_title(get_class($method)))) && $method->has_settings()) {
                 $method->admin_options();
             }
         }
     }
 }
开发者ID:WPprodigy,项目名称:woocommerce,代码行数:24,代码来源:class-wc-settings-shipping.php


注:本文中的WC_Admin_Settings::output_fields方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。