WordPress at Your Fingertips
function is not described

WC_Shortcodes::shortcode_wrapper() public WC 1.0

Shortcode Wrapper.

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

No Hooks.

Return

String.

Usage

$result = WC_Shortcodes::shortcode_wrapper(;

Code of WC_Shortcodes::shortcode_wrapper() WC 5.9.0

public static function shortcode_wrapper(
	$function,
	$atts = array(),
	$wrapper = array(
		'class'  => 'woocommerce',
		'before' => null,
		'after'  => null,
	)
) {
	ob_start();

	// @codingStandardsIgnoreStart
	echo empty( $wrapper['before'] ) ? '<div class="' . esc_attr( $wrapper['class'] ) . '">' : $wrapper['before'];
	call_user_func( $function, $atts );
	echo empty( $wrapper['after'] ) ? '</div>' : $wrapper['after'];
	// @codingStandardsIgnoreEnd

	return ob_get_clean();
}