WordPress at a glance
Главная Functions Plugins, Hooks

Category: Plugins, Hooks 15

activate_plugins()

Activates the specified plugins.

add_screen_option()

Register and configure an admin screen option

content_url()

Retrieves the URL to the content directory.

deactivate_plugins()

Deactivate a single plugin or multiple plugins.

get_file_data()

Retrieve metadata from a file.

get_plugin_data()

Parses the plugin contents to retrieve plugin's metadata.

get_plugins()

Check the plugins directory and retrieve all plugin files with plugin data.

is_plugin_active()

Check whether a plugin is active.

plugin_basename()

Gets the basename of a plugin.

plugin_dir_path()

Get the filesystem directory path (with trailing slash) for the plugin __FILE__ passed in.

plugin_dir_url()

Get the URL directory path (with trailing slash) for the plugin __FILE__ passed in.

plugins_url()

Retrieves a URL within the plugins or mu-plugins directory.

register_activation_hook()

Set the activation hook for a plugin.

register_deactivation_hook()

Set the deactivation hook for a plugin.

register_uninstall_hook()

Set the uninstallation hook for a plugin.

Hooks (actions, filters)

add_action()

Hooks a function on to a specific action.

add_filter()

Attaches the specified PHP function to the specified filter hook. Thus, when the filter is triggered, the value will be filtered by the specified PHP function.

apply_filters()

Call the functions added to a filter hook.

apply_filters_ref_array()

Execute functions hooked on a specific filter hook, specifying arguments in an array.

current_filter()

Retrieve the name of the current filter or action.

did_action()

Retrieve the number of times an action is fired.

do_action()

Execute functions hooked on a specific action hook.

do_action_ref_array()

Execute functions hooked on a specific action hook, specifying arguments in an array.

doing_filter()

Retrieve the name of a filter currently being processed.

has_action()

Check if any action has been registered for a hook.

has_filter()

Check if any filter has been registered for a hook.

remove_action()

Removes a function from a specified action hook.

remove_all_filters()

Remove all of the hooks from a filter.

remove_filter()

Removes a function from a specified filter hook.