This function has been deprecated. Use remove_allowed_options() instead. Please consider writing more inclusive code.

remove_option_whitelist( array $del_options, string|array $options = '' )

Removes a list of options from the allowed options list.


Parameters

$del_options

(Required)

$options

(Optional)

Default value: ''


Return

(array)


Source

File: wp-includes/deprecated.php

function remove_option_whitelist( $del_options, $options = '' ) {
	if ( $options == '' )
		global $whitelist_options;
	else
		$whitelist_options = $options;

	foreach ( $del_options as $page => $keys ) {
		foreach ( $keys as $key ) {
			if ( isset($whitelist_options[ $page ]) && is_array($whitelist_options[ $page ]) ) {
				$pos = array_search( $key, $whitelist_options[ $page ] );
				if ( $pos !== false )
					unset( $whitelist_options[ $page ][ $pos ] );
			}
		}
	}

	return $whitelist_options;
}


Changelog

Changelog
Version Description
5.5.0 Use remove_allowed_options() instead.<br> Please consider writing more inclusive code.
2.7.0 Introduced. This function has been deprecated. Use remove_allowed_options() instead. Please consider writing more inclusive code.