Advertisements

format_to_edit

Definition:
function format_to_edit( $content, $richedit = false ) {}

Acts on text which is about to be edited.
Unless $richedit is set, it is simply a holder for the ‘format_to_edit’ filter. If $richedit is set true htmlspecialchars(), through esc_textarea(), will be run on the content, converting special characters to HTML entities.

Parameters

  • string $content: The text about to be edited.
  • bool $richedit: Whether the $content should pass through htmlspecialchars(). Default false.

Return values

returns:The text after the filter (and possibly htmlspecialchars()) has been run.

Defined filters

  • format_to_edit
    apply_filters( 'format_to_edit', $content )

Source code

function format_to_edit( $content, $richedit = false ) {

	$content = apply_filters( 'format_to_edit', $content );

	if ( ! $richedit )

		$content = esc_textarea( $content );

	return $content;

}

1092

Advertisements

No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: