install_theme_complete_actions
云策文档标注
概述
install_theme_complete_actions 是一个 WordPress 过滤器钩子,用于在单个主题安装后过滤可用的操作链接列表。它允许开发者自定义或修改这些链接,以增强主题安装后的用户体验。
关键要点
- 这是一个过滤器钩子,用于修改主题安装完成后的操作链接数组。
- 参数包括 $install_actions(操作链接数组)、$api(WordPress.org API 主题数据对象)、$stylesheet(主题目录名)和 $theme_info(WP_Theme 主题对象)。
- 在 Theme_Installer_Skin::after() 方法中使用,自 WordPress 2.8.0 版本引入。
原文内容
Filters the list of action links available following a single theme installation.
Parameters
$install_actionsstring[]-
Array of theme action links.
$apiobject-
Object containing WordPress.org API theme data.
$stylesheetstring-
Theme directory name.
$theme_infoWP_Theme-
Theme object.
Source
$install_actions = apply_filters( 'install_theme_complete_actions', $install_actions, $this->api, $stylesheet, $theme_info );
Changelog
| Version | Description |
|---|---|
| 2.8.0 | Introduced. |