wp_oembed_ensure_format

Advertisement

Summery Summery

Ensures that the specified format is either ‘json’ or ‘xml’.

Syntax Syntax

wp_oembed_ensure_format( string $format )

Parameters Parameters

$format

(string) (Required) The oEmbed response format. Accepts 'json' or 'xml'.

Return Return

(string) The format, either 'xml' or 'json'. Default 'json'.

Source Source

File: wp-includes/embed.php

	}

	return $format;
}

/**
 * Hooks into the REST API output to print XML instead of JSON.

Advertisement

Changelog Changelog

Changelog
Version Description
4.4.0 Introduced.

Advertisement

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.