unescape_invalid_shortcodes

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

WordPress Version: 6.1

/**
 * Removes placeholders added by do_shortcodes_in_html_tags().
 *
 * @since 4.2.3
 *
 * @param string $content Content to search for placeholders.
 * @return string Content with placeholders removed.
 */
function unescape_invalid_shortcodes($content)
{
    // Clean up entire string, avoids re-parsing HTML.
    $trans = array('[' => '[', ']' => ']');
    $content = strtr($content, $trans);
    return $content;
}

WordPress Version: .10

/**
 * Remove placeholders added by do_shortcodes_in_html_tags().
 *
 * @since 4.2.3
 *
 * @param string $content Content to search for placeholders.
 * @return string Content with placeholders removed.
 */
function unescape_invalid_shortcodes($content)
{
    // Clean up entire string, avoids re-parsing HTML.
    $trans = array('[' => '[', ']' => ']');
    $content = strtr($content, $trans);
    return $content;
}