• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WooCommerce a2z

WooCommerce a2z

WooCommerce

  • Home
  • Plugins
  • Blocks
  • Shortcodes
  • APIs
  • Classes
  • Files
  • Hooks
  • Sitemap
  • Blog
Home / APIs / WC_Settings_Payment_Gateways::output() – Output the settings.

You appear to be a bot. Output may be restricted

Description

Output the settings.

Usage

WC_Settings_Payment_Gateways::output();

Parameters

Returns

void

Source

File name: woocommerce/includes/admin/settings/class-wc-settings-payment-gateways.php


Lines:

1 to 25 of 25
  public function output() {
    global $current_section;

    // Load gateways 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 ) ) ), true ) ) {
          if ( isset( $_GET['toggle_enabled'] ) ) { // WPCS: input var ok, CSRF ok.
            $enabled = $gateway->get_option( 'enabled' );

            if ( $enabled ) {
              $gateway->settings['enabled'] = wc_string_to_bool( $enabled ) ? 'no' : 'yes';
            }
          }
          $gateway->admin_options();
          break;
        }
      }
    }
    $settings = $this->get_settings( $current_section );
    WC_Admin_Settings::output_fields( $settings );
  }
 

 View on GitHub View on Trac

Published: 26th November 2019 | Last updated: 10th December 2020

Primary Sidebar

Information

Function name: WC_Settings_Payment_Gateways::output
Class ref: WC_Settings_Payment_Gateways
Plugin ref: WooCommerce
Version: 4.8.0
Sourcefile: includes/admin/settings/class-wc-settings-payment-gateways.php
File ref: includes/admin/settings/class-wc-settings-payment-gateways.php
Deprecated?: No
API Letters: G,O,P,S,W

Footer

WooCommerce a2z
WooCommerce a2z
WooCommerce
WordPress 5.6
WordPress a2z
WordPress core a2z
Genesis Theme Framework a2z
Jetpack a2z
WordPress develop tests
Easy Digital Downloads a2z
WooCommerce a2z
Yoast SEO a2z
WordPress Blocks

Site:  woocommerce.wp-a2z.org
© Copyright WooCommerce a2z 2014-2021. All rights reserved.


Website designed and developed by Herb Miller
Proudly powered by WordPress and oik plugins

  • Home
  • Blog
  • Sitemap
  • Sites