Make WordPress Core


Ignore:
Timestamp:
06/24/2024 03:10:50 PM (13 months ago)
Author:
audrasjb
Message:

Grouped Backports to the 6.3 branch.

  • Editor: Fix Path Traversal issue on Windows in Template-Part Block.
  • Editor: Sanitize Template Part HTML tag on save.
  • HTML API: Run URL attributes through esc_url().

Merges [58470], [58471], [58472] and [58473] to the 6.3 branch.
Props xknown, peterwilsoncc, jorbin, bernhard-reiter, azaozz, dmsnell, gziolo.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/6.3/src/wp-includes/formatting.php

    r56244 r58476  
    47864786 *
    47874787 * @since 2.5.0
     4788 * @since 6.5.5 Allow hyphens in tag names (i.e. custom elements).
    47884789 *
    47894790 * @param string $tag_name
     
    47914792 */
    47924793function tag_escape( $tag_name ) {
    4793     $safe_tag = strtolower( preg_replace( '/[^a-zA-Z0-9_:]/', '', $tag_name ) );
     4794    $safe_tag = strtolower( preg_replace( '/[^a-zA-Z0-9-_:]/', '', $tag_name ) );
    47944795    /**
    47954796     * Filters a string cleaned and escaped for output as an HTML tag.
Note: See TracChangeset for help on using the changeset viewer.