wphooks.info - pre_oembed_result

pre_oembed_result

(trunk - 5.1-alpha-44286)

The hook occurs in the following file:

wp-includes/class-oembed.php:
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
		 *
		 * Passing a non-null value to the filter will effectively short-circuit retrieval,
		 * returning the passed value instead.
		 *
		 * @since 4.5.3
		 *
		 * @param null|string $result The UNSANITIZED (and potentially unsafe) HTML that should be used to embed. Default null.
		 * @param string      $url    The URL to the content that should be attempted to be embedded.
		 * @param array       $args   Optional. Arguments, usually passed from a shortcode. Default empty.
		 */
		$pre = apply_filters( 'pre_oembed_result', null, $url, $args );

		if ( null !== $pre ) {
			return $pre;
		}

		$data = $this->get_data( $url, $args );

		if ( false === $data ) {
			return false;