WP_REST_URL_Details_Controller::prepare_metadata_for_output() – Prepares the metadata by: – stripping all HTML tags and tag entities.

You appear to be a bot. Output may be restricted

Description

Prepares the metadata by:

  • stripping all HTML tags and tag entities.
  • converting non-tag entities into characters.

Usage

$string = WP_REST_URL_Details_Controller::prepare_metadata_for_output( $metadata );

Parameters

$metadata
( string ) required – The metadata content to prepare.

Returns

string The prepared metadata.

Source

File name: wordpress/wp-includes/rest-api/endpoints/class-wp-rest-url-details-controller.php
Lines:

1 to 5 of 5
  private function prepare_metadata_for_output( $metadata ) {
    $metadata = html_entity_decode( $metadata, ENT_QUOTES, get_bloginfo( 'charset' ) );
    $metadata = wp_strip_all_tags( $metadata );
    return $metadata;
  }
 

 View on GitHub View on Trac