Changeset 37708 for trunk/src/wp-includes/class-oembed.php
- Timestamp:
- 06/15/2016 11:22:52 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-oembed.php
r37518 r37708 316 316 */ 317 317 public function get_html( $url, $args = '' ) { 318 /** 319 * Filters the oEmbed result before any HTTP requests are made. 320 * 321 * This allows one to short-circuit the default logic, perhaps by 322 * replacing it with a routine that is more optimal for your setup. 323 * 324 * Passing a non-null value to the filter will effectively short-circuit retrieval, 325 * returning the passed value instead. 326 * 327 * @since 4.5.3 328 * 329 * @param null|string $result The UNSANITIZED (and potentially unsafe) HTML that should be used to embed. Default null. 330 * @param string $url The URL to the content that should be attempted to be embedded. 331 * @param array $args Optional. Arguments, usually passed from a shortcode. Default empty. 332 */ 333 $pre = apply_filters( 'pre_oembed_result', null, $url, $args ); 334 335 if ( null !== $pre ) { 336 return $pre; 337 } 338 318 339 $provider = $this->get_provider( $url, $args ); 319 340 320 if ( !$provider || false === $data = $this->fetch( $provider, $url, $args ) ) 321 return false; 341 if ( ! $provider || false === $data = $this->fetch( $provider, $url, $args ) ) { 342 return false; 343 } 322 344 323 345 /**
Note: See TracChangeset
for help on using the changeset viewer.