[ Index ]

PHP Cross Reference of WordPress Trunk (Updated Daily)

Search

title

Body

[close]

/wp-includes/ -> class-wp-theme-json-data.php (summary)

WP_Theme_JSON_Data class

File Size: 83 lines (2 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

WP_Theme_JSON_Data:: (4 methods):
  __construct()
  update_with()
  get_data()
  get_theme_json()


Class: WP_Theme_JSON_Data  - X-Ref

Class to provide access to update a theme.json structure.

__construct( $data = array( 'version' => WP_Theme_JSON::LATEST_SCHEMA )   X-Ref
Constructor.

param: array  $data   Array following the theme.json specification.
param: string $origin The origin of the data: default, theme, user.

update_with( $new_data )   X-Ref
Updates the theme.json with the the given data.

param: array $new_data Array following the theme.json specification.
return: WP_Theme_JSON_Data The own instance with access to the modified data.

get_data()   X-Ref
Returns an array containing the underlying data
following the theme.json specification.

return: array

get_theme_json()   X-Ref
Returns theme JSON object.

return: WP_Theme_JSON The theme JSON structure stored in this data object.



Generated : Tue Dec 24 08:20:01 2024 Cross-referenced by PHPXref