WordPress build repository browser

Changeset 63646


Ignore:
Timestamp:
10/19/2026 05:57:49 AM (4 days ago)
Author:
jonsurrell
Message:

Script Loader: Document wp_inline_script_attributes $data parameter quirk.

Developed in: ​https://github.com/WordPress/wordpress-develop/pull/14281

Props jonsurrell, westonruter.
See #65860, #66308.

Built from ​https://develop.svn.wordpress.org/trunk@64496

Location:
trunk/wp-includes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/script-loader.php

    r63635 r63646  
    35893589         * Filters attributes to be added to a script tag.
    35903590         *
     3591         * Escaping and normalization can make the text a browser parses from the printed tag differ
     3592         * from `$data`. A callback that needs that text, such as one computing a CSP hash, can set
     3593         * `$data` as the modifiable text of a SCRIPT tag in a `WP_HTML_Tag_Processor` with the
     3594         * filtered attributes applied and then read {@see WP_HTML_Tag_Processor::get_modifiable_text()},
     3595         * at a late priority so that the attributes are final.
     3596         *
    35913597         * @since 5.7.0
    35923598         *
  • trunk/wp-includes/version.php

    r63645 r63646  
    1717 * @global string $wp_version
    1818 */
    19 $wp_version = '7.2-alpha-64495';
     19$wp_version = '7.2-alpha-64496';
    2020
    2121/**
Note: See TracChangeset for help on using the changeset viewer.