2020-05-02 / 5078阅 / 悠然
挂钩功能>
动作是WordPress核心在执行期间或特定事件发生时在特定点启动的挂钩。插件可以指定>
(string)
(Required)
The name of the action to which the $function_to_add is hooked.
(callable)
(Required)
The name of the function you wish to be called.
(int)
(Optional)
Used to specify the order in which the functions associated with a particular action are executed. Lower numbers correspond with earlier execution, and functions with the same priority are executed in the order in which they were added to the action.
Default value: 10
(int)
(Optional)
The number of arguments the function accepts.
Default value: 1
(true) Will always return true.