Make WordPress Core

Changeset 53844


Ignore:
Timestamp:
08/05/2022 02:10:03 PM (4 years ago)
Author:
audrasjb
Message:

Plugins: Properly encode query string s parameter in plugin search.

This ensures special characters like & are properly encoded when passed as URL parameter.

Props praful2111, audrasjb, costdev.
Fixes #56339.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/js/_enqueues/wp/updates.js

    r53124 r53844  
    25362536                        data = {
    25372537                                _ajax_nonce: wp.updates.ajaxNonce,
    2538                                 s:           event.target.value,
     2538                                s:           encodeURIComponent( event.target.value ),
    25392539                                tab:         'search',
    25402540                                type:        $( '#typeselector' ).val(),
     
    26132613                        var data = {
    26142614                                _ajax_nonce:   wp.updates.ajaxNonce,
    2615                                 s:             event.target.value,
     2615                                s:             encodeURIComponent( event.target.value ),
    26162616                                pagenow:       pagenow,
    26172617                                plugin_status: 'all'
Note: See TracChangeset for help on using the changeset viewer.