WordPress at a glance
filter is not described

wp_code_editor_settings filter-hook . WP 4.9.0

Filters settings that are passed into the code editor.

Returning a falsey value will disable the syntax-highlighting code editor.

Usage

add_filter( 'wp_code_editor_settings', 'filter_function_name_3308', 10, 2 );
function filter_function_name_3308( $settings, $args ){
	// filter...

	return $settings;
}
$settings(array)
The array of settings passed to the code editor. A falsey value disables the editor.
$args(array)

Args passed when calling get_code_editor_settings().

  • $type (string)
    The MIME type of the file to be edited.

  • $file (string)
    Filename being edited.

  • $theme (WP_Theme)
    Theme being edited when on theme editor.

  • $plugin (string)
    Plugin being edited when on plugin editor.

  • $codemirror (array)
    Additional CodeMirror setting overrides.

  • $csslint (array)
    CSSLint rule overrides.

  • $jshint (array)
    JSHint rule overrides.

  • $htmlhint (array)
    JSHint rule overrides.

Where the hook is called

wp_get_code_editor_settings()
wp-includes/general-template.php 3535
return apply_filters( 'wp_code_editor_settings', $settings, $args );

Where the hook is used (in WP core)

Does not used.