_cleanup_image_add_caption() – Private preg_replace callback used in image_add_caption()

You appear to be a bot. Output may be restricted

Description

Private preg_replace callback used in image_add_caption().

Usage

_cleanup_image_add_caption( $matches );

Parameters

$matches
( mixed ) required

Returns

void

Source

File name: wordpress/wp-admin/includes/media.php
Lines:

1 to 4 of 4
function _cleanup_image_add_caption( $matches ) {
  // Remove any line breaks from inside the tags.
  return preg_replace( '/[\r\n\t]+/', ' ', $matches[0] );
}
 

 View on GitHub View on Trac