WordPress at Your Fingertips
function is not described

WC_Admin_Setup_Wizard::wc_setup_payment() public WC 1.0

Deprecated from version 4.6.0. It is no longer supported and can be removed in future releases. It is recommended to replace this function with the same one.

Payment Step.

{} It's a method of the class: WC_Admin_Setup_Wizard{}

No Hooks.

Return

null. Nothing.

Usage

$WC_Admin_Setup_Wizard = new WC_Admin_Setup_Wizard();
$WC_Admin_Setup_Wizard->wc_setup_payment();

Changelog

Deprecated 4.6.0

Code of WC_Admin_Setup_Wizard::wc_setup_payment() WC 5.9.0

<?php
public function wc_setup_payment() {
	_deprecated_function( __CLASS__ . '::' . __FUNCTION__, '4.6.0', 'Onboarding is maintained in WooCommerce Admin.' );
	$featured_gateways = array_filter( $this->get_wizard_in_cart_payment_gateways(), array( $this, 'is_featured_service' ) );
	$in_cart_gateways  = array_filter( $this->get_wizard_in_cart_payment_gateways(), array( $this, 'is_not_featured_service' ) );
	$manual_gateways   = $this->get_wizard_manual_payment_gateways();
	?>
	<h1><?php esc_html_e( 'Payment', 'woocommerce' ); ?></h1>
	<form method="post" class="wc-wizard-payment-gateway-form">
		<p>
			<?php
			printf(
				wp_kses(
					/* translators: %s: Link */
					__( 'WooCommerce can accept both online and offline payments. <a href="%s" target="_blank">Additional payment methods</a> can be installed later.', 'woocommerce' ),
					array(
						'a' => array(
							'href'   => array(),
							'target' => array(),
						),
					)
				),
				esc_url( admin_url( 'admin.php?page=wc-addons&section=payment-gateways' ) )
			);
			?>
		</p>
		<?php if ( $featured_gateways ) : ?>
		<ul class="wc-wizard-services featured">
			<?php
			foreach ( $featured_gateways as $gateway_id => $gateway ) {
				$this->display_service_item( $gateway_id, $gateway );
			}
			?>
		</ul>
		<?php endif; ?>
		<?php if ( $in_cart_gateways ) : ?>
		<ul class="wc-wizard-services in-cart">
			<?php
			foreach ( $in_cart_gateways as $gateway_id => $gateway ) {
				$this->display_service_item( $gateway_id, $gateway );
			}
			?>
		</ul>
		<?php endif; ?>
		<ul class="wc-wizard-services manual">
			<li class="wc-wizard-services-list-toggle closed">
				<div class="wc-wizard-service-name">
					<?php esc_html_e( 'Offline Payments', 'woocommerce' ); ?>
				</div>
				<div class="wc-wizard-service-description">
					<?php esc_html_e( 'Collect payments from customers offline.', 'woocommerce' ); ?>
				</div>
				<div class="wc-wizard-service-enable" tabindex="0">
					<input class="wc-wizard-service-list-toggle" id="wc-wizard-service-list-toggle" type="checkbox">
					<label for="wc-wizard-service-list-toggle"></label>
				</div>
			</li>
			<?php
			foreach ( $manual_gateways as $gateway_id => $gateway ) {
				$this->display_service_item( $gateway_id, $gateway );
			}
			?>
		</ul>
		<p class="wc-setup-actions step">
			<?php $this->plugin_install_info(); ?>
			<button type="submit" class="button-primary button button-large button-next" value="<?php esc_attr_e( 'Continue', 'woocommerce' ); ?>" name="save_step"><?php esc_html_e( 'Continue', 'woocommerce' ); ?></button>
			<?php wp_nonce_field( 'wc-setup' ); ?>
		</p>
	</form>
	<?php
}