taxonomy_meta_box_sanitize_cb_checkboxes

The timeline below displays how wordpress function taxonomy_meta_box_sanitize_cb_checkboxes has changed across different WordPress versions. If a version is not listed, refer to the next available version below.

WordPress Version: 5.4

/**
 * Sanitizes POST values from a checkbox taxonomy metabox.
 *
 * @since 5.1.0
 *
 * @param string $taxonomy The taxonomy name.
 * @param array  $terms    Raw term data from the 'tax_input' field.
 * @return int[] Array of sanitized term IDs.
 */
function taxonomy_meta_box_sanitize_cb_checkboxes($taxonomy, $terms)
{
    return array_map('intval', $terms);
}

WordPress Version: 5.1

/**
 * Sanitizes POST values from a checkbox taxonomy metabox.
 *
 * @since 5.1.0
 *
 * @param mixed $terms Raw term data from the 'tax_input' field.
 * @return array
 */
function taxonomy_meta_box_sanitize_cb_checkboxes($taxonomy, $terms)
{
    return array_map('intval', $terms);
}