WC_Admin_Setup_Wizard::wc_setup_payment()
Устарела с версии 4.6.0. Больше не поддерживается и может быть удалена. Рекомендуется заменить эту функцию на аналог.
Payment Step.
Метод класса: WC_Admin_Setup_Wizard{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$WC_Admin_Setup_Wizard = new WC_Admin_Setup_Wizard(); $WC_Admin_Setup_Wizard->wc_setup_payment();
Список изменений
Устарела с | 4.6.0 |
Код WC_Admin_Setup_Wizard::wc_setup_payment() WC Admin Setup Wizard::wc setup payment WC 8.7.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§ion=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 }