WordPress at a glance
function is not described

wc_sanitize_tooltip() WC 2.3.10

Sanitize a string destined to be a tooltip.

No Hooks.

Return

String. Nothing.

Usage

wc_sanitize_tooltip( $var );
$var(string) (required)
Data to sanitize.

Changelog

Since 2.3.10 Introduced.
Since 2.3.10 Tooltips are encoded with htmlspecialchars to prevent XSS. Should not be used in conjunction with esc_attr()

Code of wc_sanitize_tooltip() WC 5.2.2

<?php
function wc_sanitize_tooltip( $var ) {
	return htmlspecialchars(
		wp_kses(
			html_entity_decode( $var ),
			array(
				'br'     => array(),
				'em'     => array(),
				'strong' => array(),
				'small'  => array(),
				'span'   => array(),
				'ul'     => array(),
				'li'     => array(),
				'ol'     => array(),
				'p'      => array(),
			)
		)
	);
}