unregister_setting()注销删除一个设置项目

目录

描述

Allows clean de-registration of registered settings. Should be used mostly in deactivation hooks.

unregister_setting() 描述

用法

<?php unregister_setting$option_group$option_name$sanitize_callback ); ?>

unregister_setting() 用法

参数

$option_group

(string) (必填) Group the option belongs to (used in register_setting).

默认值: None

$option_name

(string) (必填) Name of the option

默认值: None

$sanitize_callback

(string) (可选) Function that fills the section with the desired content. The function should echo its output.

默认值: (Empty string)

unregister_setting() 参数

返回值

(void) 

This function does not return a value.

unregister_setting() 返回值

历史

添加于 版本: 2.7.0

unregister_setting() 历史

源文件

unregister_setting() 函数的代码位于 wp-admin/includes/plugin.php.

unregister_setting() 源文件

相关