Automattic\WooCommerce\Blocks\Domain\Services

CheckoutFieldsFrontend::render_order_address_fields()publicWC 1.0

Renders address fields on the order details page.

Method of the class: CheckoutFieldsFrontend{}

No Hooks.

Return

null. Nothing (null).

Usage

$CheckoutFieldsFrontend = new CheckoutFieldsFrontend();
$CheckoutFieldsFrontend->render_order_address_fields( $address_type, $order );
$address_type(string) (required)
Type of address (billing or shipping).
$order(WC_Order) (required)
Order object.

CheckoutFieldsFrontend::render_order_address_fields() code WC 9.0.1

public function render_order_address_fields( $address_type, $order ) {
	// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
	echo $this->render_additional_fields( $this->checkout_fields_controller->get_order_additional_fields_with_values( $order, 'address', $address_type, 'view' ) );
}