WordPress.org

Make WordPress Core


Ignore:
Timestamp:
10/28/2014 06:34:16 PM (6 years ago)
Author:
pento
Message:

Add wp_json_encode(), a wrapper for json_encode() that ensures everything is converted to UTF-8.

Change all core calls from json_encode() to wp_json_encode().

Fixes #28786.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-themes-list-table.php

    r29767 r30055  
    274274            $args = array_merge( $args, $extra_args );
    275275
    276         printf( "<script type='text/javascript'>var theme_list_args = %s;</script>\n", json_encode( $args ) );
     276        printf( "<script type='text/javascript'>var theme_list_args = %s;</script>\n", wp_json_encode( $args ) );
    277277        parent::_js_vars();
    278278    }
Note: See TracChangeset for help on using the changeset viewer.