函数原型
doing_action( string|null $hook_name = null ): bool
函数描述
Returns whether or not an action hook is currently being processed.
是否弃用
未弃用
函数参数
-
$hook_name
string|null
Optional - Action hook to check. Defaults to null, which checks if any action is currently being run.
Default:
null
函数返回值
bool Whether the action is currently in the stack.
函数位置
File: wp-includes/plugin.php.
函数源码
function doing_action( $hook_name = null ) {
return doing_filter( $hook_name );
}
源码链接
变更日志
| Version | Description |
|---|---|
| 3.9.0 | Introduced. |

