wp_get_list_item_separator

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

WordPress Version: 6.2

/**
 * Retrieves the list item separator based on the locale.
 *
 * @since 6.0.0
 *
 * @global WP_Locale $wp_locale WordPress date and time locale object.
 *
 * @return string Locale-specific list item separator.
 */
function wp_get_list_item_separator()
{
    global $wp_locale;
    if (!$wp_locale instanceof WP_Locale) {
        // Default value of WP_Locale::get_list_item_separator().
        /* translators: Used between list items, there is a space after the comma. */
        return __(', ');
    }
    return $wp_locale->get_list_item_separator();
}

WordPress Version: 6.1

/**
 * Retrieves the list item separator based on the locale.
 *
 * @since 6.0.0
 *
 * @global WP_Locale $wp_locale WordPress date and time locale object.
 *
 * @return string Locale-specific list item separator.
 */
function wp_get_list_item_separator()
{
    global $wp_locale;
    return $wp_locale->get_list_item_separator();
}