---
url: https://docs.zblogcn.com/php/dev-interfaces.md
description: 介绍 Z-BlogPHP 插件接口的分类与挂载方式，包括管理页面输出、前台页面输出、数据写入处理、魔术方法扩展与流程事件监听等类别。
---

# 接口列表

Z-BlogPHP 提供了多类插件接口供开发者扩展系统功能。本篇按接口分类说明各类接口的用途与挂载方式。

## 接口分类

为了应对各种各样的扩展需求，Z-BlogPHP 提供了几类插件接口供开发者使用，简要说明如下：

* **「管理页面」输出类**：这一类接口一般用于在后台现有管理页面中添加按钮或者扩展选项内容
* **「前台页面」输出类**：在网页内容输出到浏览器前进行变更或追加，包括额外引入样式、脚本。
* **「数据写入」处理类**：在文章、评论等数据提交的过程中，具体又分为：
  * **Core**：在数据提交前介入，可用于过滤提交的数据内容。
  * **Succeed**：在数据提交成功后介入，可用于数据提交后的事件处理，如更新自定义模块数据等。
* **「魔术方法」扩展类**：用于扩展系统类中的可用方法
* **「流程/事件」监听类**：严格来说，全部接口都是「监听」，监听接口本身被触发，然后执行指定的操作，或者对接口传递的数据进行处理。
  * 除「魔术方法」外，前三种是类别其实是以「功能目的」来划分的，也只是较常用的三种。

**注：下边列表并不严格对应上边分类；**

## 「管理页面」输出

### 后台全局输出

| 接口                         | 参数             | 说明                           |
| ---------------------------- | ---------------- | ------------------------------ |
| [Filter_Plugin_Admin_Header](/php/dev-examples/admin-global/header)   |                  | 用于向后台「header」输出内容   |
| [Filter_Plugin_Admin_Footer](/php/dev-examples/admin-global/footer)   |                  | 用于向后台「footer」输出内容   |
| [Filter_Plugin_Admin_TopMenu](/php/dev-examples/admin-global/top-menu)  | `arr $topmenus`  | 用于向后台「顶部菜单」添加项目 |
| [Filter_Plugin_Admin_LeftMenu](/php/dev-examples/admin-global/left-menu) | `arr $leftmenus` | 用于向后台「侧栏菜单」添加项目 |

### 特定页 菜单管理 SubMenu

用法示例详见「[后台子菜单扩展案例](/php/dev-examples/submenu/)」。

| 接口                                    | 参数 | 说明 |
| --------------------------------------- | ---- | ---- |
| [Filter_Plugin_Admin_SiteInfo_SubMenu](/php/dev-examples/submenu/site-info)    |      | 后台首页页面子菜单   |
| [Filter_Plugin_Admin_ArticleMng_SubMenu](/php/dev-examples/submenu/article-mng)  |      | 文章管理页面子菜单   |
| [Filter_Plugin_Admin_PageMng_SubMenu](/php/dev-examples/submenu/page-mng)     |      | 页面管理页面子菜单   |
| [Filter_Plugin_Admin_CategoryMng_SubMenu](/php/dev-examples/submenu/category-mng) |      | 分类管理页面子菜单   |
| [Filter_Plugin_Admin_CommentMng_SubMenu](/php/dev-examples/submenu/comment-mng)  |      | 评论管理页面子菜单   |
| [Filter_Plugin_Admin_MemberMng_SubMenu](/php/dev-examples/submenu/member-mng)   |      | 用户管理页面子菜单   |
| [Filter_Plugin_Admin_UploadMng_SubMenu](/php/dev-examples/submenu/upload-mng)   |      | 附件管理页面子菜单   |
| [Filter_Plugin_Admin_TagMng_SubMenu](/php/dev-examples/submenu/tag-mng)      |      | 标签管理页面子菜单   |
| [Filter_Plugin_Admin_PluginMng_SubMenu](/php/dev-examples/submenu/plugin-mng)   |      | 插件管理页面子菜单   |
| [Filter_Plugin_Admin_ThemeMng_SubMenu](/php/dev-examples/submenu/theme-mng)    |      | 主题管理页面子菜单   |
| [Filter_Plugin_Admin_ModuleMng_SubMenu](/php/dev-examples/submenu/module-mng)   |      | 模块管理页面子菜单   |
| [Filter_Plugin_Admin_SettingMng_SubMenu](/php/dev-examples/submenu/setting-mng)  |      | 设置管理页面子菜单   |
| [Filter_Plugin_Edit_SubMenu](/php/dev-examples/submenu/edit)              |      | 编辑页菜单          |
| [Filter_Plugin_Tag_Edit_SubMenu](/php/dev-examples/submenu/tag-edit)          |      | 标签编辑页菜单       |
| [Filter_Plugin_Module_Edit_SubMenu](/php/dev-examples/submenu/module-edit)       |      | 模块编辑页菜单       |
| [Filter_Plugin_Member_Edit_SubMenu](/php/dev-examples/submenu/member-edit)       |      | 用户编辑页菜单       |
| [Filter_Plugin_Category_Edit_SubMenu](/php/dev-examples/submenu/category-edit)     |      | 分类编辑页菜单       |

### 特定页表格过滤

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_Admin_ArticleMng_Table](/php/dev-examples/admin-table/article-mng) | `Post &$article, arr &$tabletds, arr &$tableths` | 文章管理页表格每行处理 |
| [Filter_Plugin_Admin_PageMng_Table](/php/dev-examples/admin-table/page-mng) | `Post &$article, arr &$tabletds, arr &$tableths` | 页面管理页表格每行处理 |
| [Filter_Plugin_Admin_CategoryMng_Table](/php/dev-examples/admin-table/category-mng) | `Category &$category, arr &$tabletds, arr &$tableths` | 分类管理页表格每行处理 |
| [Filter_Plugin_Admin_CommentMng_Table](/php/dev-examples/admin-table/comment-mng) | `Comment &$cmt, arr &$tabletds, arr &$tableths, Post $article` | 评论管理页表格每行处理 |
| [Filter_Plugin_Admin_MemberMng_Table](/php/dev-examples/admin-table/member-mng) | `Member &$member, arr &$tabletds, arr &$tableths` | 用户管理页表格每行处理 |
| [Filter_Plugin_Admin_UploadMng_Table](/php/dev-examples/admin-table/upload-mng) | `Upload &$upload, arr &$tabletds, arr &$tableths` | 附件管理页表格每行处理 |
| [Filter_Plugin_Admin_TagMng_Table](/php/dev-examples/admin-table/tag-mng) | `Tag &$tag, arr &$tabletds, arr &$tableths` | 标签管理页表格每行处理 |

### 特定页查询过滤

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| `Filter_Plugin_Admin_ArticleMng_Core` | `$s, $w, $or, $l, $op` | 文章管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_PageMng_Core` | `$s, $w, $or, $l, $op` | 页面管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_CommentMng_Core` | `$s, $w, $or, $l, $op` | 评论管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_CategoryMng_Core` | `$s, $w, $or, $l, $op` | 分类管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_MemberMng_Core` | `$s, $w, $or, $l, $op` | 会员管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_UploadMng_Core` | `$s, $w, $or, $l, $op` | 附件管理页的核心接口（1.7 新加入） |
| `Filter_Plugin_Admin_TagMng_Core` | `$s, $w, $or, $l, $op` | 标签管理页的核心接口（1.7 新加入） |

### 特定页输出

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_Edit_Begin](/php/dev-examples/admin-edit/edit-begin) | | 文章/页面编辑页头部输出 |
| [Filter_Plugin_Edit_End](/php/dev-examples/admin-edit/edit-end) | | 文章/页面编辑页尾部输出 |
| [Filter_Plugin_Edit_Response](/php/dev-examples/admin-edit/edit-response) | | 编辑页正文编辑器之后输出 |
| [Filter_Plugin_Edit_Response2](/php/dev-examples/admin-edit/edit-response2) | | 编辑页摘要编辑器之后输出 |
| [Filter_Plugin_Edit_Response3](/php/dev-examples/admin-edit/edit-response3) | | 编辑页右侧发布栏输出 |
| [Filter_Plugin_Edit_Response4](/php/dev-examples/admin-edit/edit-response4) | | 编辑页标题输入框之前输出 |
| [Filter_Plugin_Edit_Response5](/php/dev-examples/admin-edit/edit-response5) | | 编辑页标题与正文之间输出 |
| [Filter_Plugin_Category_Edit_Response](/php/dev-examples/admin-edit/category-edit-response) | | 分类编辑页表单字段之后输出 |
| [Filter_Plugin_Tag_Edit_Response](/php/dev-examples/admin-edit/tag-edit-response) | | 标签编辑页表单字段之后输出 |
| [Filter_Plugin_Member_Edit_Response](/php/dev-examples/admin-edit/member-edit-response) | | 用户编辑页表单字段之后输出 |
| [Filter_Plugin_Module_Edit_Response](/php/dev-examples/admin-edit/module-edit-response) | | 模块编辑页表单字段之后输出 |

## 「管理页面」流程监听

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_Admin_Begin](/php/dev-examples/admin-process/begin) | | 后台管理页启动时触发 |
| [Filter_Plugin_Admin_End](/php/dev-examples/admin-process/end) | | 后台管理页输出完成后触发 |

## 「前台页面」输出

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_ViewList_Template](/php/dev-examples/view-template/list) | `Template $template` | 列表页模板渲染前触发 |
| [Filter_Plugin_ViewPost_Template](/php/dev-examples/view-template/post) | `Template $template` | 文章/页面详情页模板渲染前触发 |
| [Filter_Plugin_ViewSearch_Template](/php/dev-examples/view-template/search) | `Template $template` | 搜索结果页模板渲染前触发 |
| [Filter_Plugin_ViewComments_Template](/php/dev-examples/view-template/comments) | `Template $template` | 评论列表（AJAX）模板渲染前触发 |
| [Filter_Plugin_ViewComment_Template](/php/dev-examples/view-template/comment) | `Template $template` | 单条评论（AJAX）模板渲染前触发 |

## 「前台页面」流程

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_Index_Begin](/php/dev-examples/view-flow/index-begin) | | 前台 index.php 启动后触发 |
| [Filter_Plugin_Index_End](/php/dev-examples/view-flow/index-end) | | 前台 index.php 渲染完成后触发 |
| [Filter_Plugin_ViewIndex_Begin](/php/dev-examples/view-flow/view-index-begin) | `str $url` | 首页渲染入口触发 |
| [Filter_Plugin_ViewAuto_Begin](/php/dev-examples/view-flow/view-auto-begin) | `str $inpurl, str $url` | 路由解析开始时触发 |
| [Filter_Plugin_ViewAuto_End](/php/dev-examples/view-flow/view-auto-end) | `str $url` | 路由解析结束时触发 |
| [Filter_Plugin_Feed_Begin](/php/dev-examples/view-flow/feed-begin) | | feed.php 启动后触发 |
| [Filter_Plugin_Feed_End](/php/dev-examples/view-flow/feed-end) | | feed.php 输出完成后触发 |
| [Filter_Plugin_ViewFeed_Begin](/php/dev-examples/view-flow/view-feed-begin) | | RSS 生成开始时触发 |
| [Filter_Plugin_ViewFeed_Core](/php/dev-examples/view-flow/view-feed-core) | `arr $w` | RSS 查询条件组装时触发 |
| [Filter_Plugin_ViewFeed_End](/php/dev-examples/view-flow/view-feed-end) | `obj $rss2` | RSS 对象输出前触发 |
| [Filter_Plugin_ViewList_Begin](/php/dev-examples/view-flow/view-list-begin) | | 列表查询开始时触发 |
| [Filter_Plugin_ViewList_Core](/php/dev-examples/view-flow/view-list-core) | `$type, $page, $category, $author, $datetime, $tag, &$w, &$pagebar, &$list_template` | 列表查询条件组装后触发 |
| [Filter_Plugin_Search_Begin](/php/dev-examples/view-flow/search-begin) | | search.php 启动后触发 |
| [Filter_Plugin_Search_End](/php/dev-examples/view-flow/search-end) | | search.php 渲染完成后触发 |
| [Filter_Plugin_ViewSearch_Begin](/php/dev-examples/view-flow/view-search-begin) | | 搜索页查询开始时触发 |
| [Filter_Plugin_ViewSearch_Core](/php/dev-examples/view-flow/view-search-core) | `$q, $page, &$w, &$pagebar, &$order` | 搜索查询条件组装后触发 |
| [Filter_Plugin_ViewPost_Begin](/php/dev-examples/view-flow/view-post-begin) | | 文章查询开始时触发 |
| [Filter_Plugin_ViewPost_Core](/php/dev-examples/view-flow/view-post-core) | `&$select, &$w, &$order, $limit, $option` | 文章查询条件组装后触发 |

## 「数据写入」处理

### 提交前过滤（Core）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_PostArticle_Core`](/php/dev-examples/data/post-article-core.md) | `&$article` | 文章编辑的核心接口 |
| [`Filter_Plugin_PostPage_Core`](/php/dev-examples/data/post-page-core.md) | `&$article` | 页面编辑的核心接口 |
| [`Filter_Plugin_PostComment_Core`](/php/dev-examples/data/post-comment-core.md) | `&$cmt` | 评论发表的核心接口 |
| [`Filter_Plugin_PostCategory_Core`](/php/dev-examples/data/post-category-core.md) | `&$cate` | 分类编辑的核心接口 |
| [`Filter_Plugin_PostTag_Core`](/php/dev-examples/data/post-tag-core.md) | `&$tag` | 标签编辑的核心接口 |
| [`Filter_Plugin_PostMember_Core`](/php/dev-examples/data/post-member-core.md) | `&$mem` | 会员编辑的核心接口 |
| [`Filter_Plugin_PostModule_Core`](/php/dev-examples/data/post-module-core.md) | `&$mod` | 模块编辑的核心接口 |
| [`Filter_Plugin_CheckComment_Core`](/php/dev-examples/data/check-comment-core.md) | `&$cmt` | 评论审核的核心接口 |
| [`Filter_Plugin_PostPost_Core`](/php/dev-examples/data/post-post-core.md) | `&$post` | Post 类对象的通用编辑的核心接口（1.7.0 加入） |
| [`Filter_Plugin_DelPost_Core`](/php/dev-examples/data/del-post-core.md) | `&$post` | Post 类对象的通用删除核心接口（1.7.0 加入） |

### 提交后处理（Succeed）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_PostArticle_Succeed`](/php/dev-examples/data/post-article-succeed.md) | `&$article` | 文章编辑成功的接口 |
| [`Filter_Plugin_PostPage_Succeed`](/php/dev-examples/data/post-page-succeed.md) | `&$article` | 页面编辑成功的接口 |
| [`Filter_Plugin_PostComment_Succeed`](/php/dev-examples/data/post-comment-succeed.md) | `&$cmt` | 评论发表成功的接口 |
| [`Filter_Plugin_PostCategory_Succeed`](/php/dev-examples/data/post-category-succeed.md) | `&$cate` | 分类编辑成功的接口 |
| [`Filter_Plugin_PostTag_Succeed`](/php/dev-examples/data/post-tag-succeed.md) | `&$tag` | 标签编辑成功的接口 |
| [`Filter_Plugin_PostMember_Succeed`](/php/dev-examples/data/post-member-succeed.md) | `&$mem` | 会员编辑成功的接口 |
| [`Filter_Plugin_PostModule_Succeed`](/php/dev-examples/data/post-module-succeed.md) | `&$mod` | 模块编辑成功的接口 |
| [`Filter_Plugin_PostUpload_Succeed`](/php/dev-examples/data/post-upload-succeed.md) | `&$upload` | 附件上传成功的接口 |
| [`Filter_Plugin_CheckComment_Succeed`](/php/dev-examples/data/check-comment-succeed.md) | `&$cmt` | 评论审核成功的接口 |
| [`Filter_Plugin_PostPost_Succeed`](/php/dev-examples/data/post-post-succeed.md) | `&$post` | Post 类对象的通用编辑的成功接口（1.7.0 加入） |
| [`Filter_Plugin_DelPost_Succeed`](/php/dev-examples/data/del-post-succeed.md) | `&$post` | Post 类对象的通用删除成功接口（1.7.0 加入） |
| [`Filter_Plugin_DelArticle_Succeed`](/php/dev-examples/data/del-article-succeed.md) | `&$article` | 文章删除成功的接口 |
| [`Filter_Plugin_DelPage_Succeed`](/php/dev-examples/data/del-page-succeed.md) | `&$article` | 页面删除成功的接口 |
| [`Filter_Plugin_DelCategory_Succeed`](/php/dev-examples/data/del-category-succeed.md) | `&$cate` | 分类删除成功的接口 |
| [`Filter_Plugin_DelTag_Succeed`](/php/dev-examples/data/del-tag-succeed.md) | `&$tag` | 标签删除成功的接口 |
| [`Filter_Plugin_DelComment_Succeed`](/php/dev-examples/data/del-comment-succeed.md) | `&$cmt` | 评论删除成功的接口 |
| [`Filter_Plugin_DelMember_Succeed`](/php/dev-examples/data/del-member-succeed.md) | `&$mem` | 会员删除成功的接口 |
| [`Filter_Plugin_DelModule_Succeed`](/php/dev-examples/data/del-module-succeed.md) | `&$mod` | 模块删除成功的接口 |

## 「魔术方法」扩展

### 文章（Post）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Post_Url`](/php/dev-examples/magic/post-url) | `&$this` | 干预 Post 类 Url 方法的接口 |
| [`Filter_Plugin_Post_Get`](/php/dev-examples/magic/post-get) | `&$this, $method` | 干预 Post 类 Get 方法的接口 |
| [`Filter_Plugin_Post_Set`](/php/dev-examples/magic/post-set) | `&$this, $method, $arg` | 干预 Post 类 Set 方法的接口 |
| [`Filter_Plugin_Post_Save`](/php/dev-examples/magic/post-save) | `&$post` | Post 类的 Save 方法接口 |
| [`Filter_Plugin_Post_Del`](/php/dev-examples/magic/post-del) | `&$post` | Post 类的 Del 方法接口 |
| [`Filter_Plugin_Post_Call`](/php/dev-examples/magic/post-call) | `&$post, $method, $args` | Post 类的魔术方法接口 |
| [`Filter_Plugin_Post_Thumbs`](/php/dev-examples/magic/post-thumbs) | `&$this, &$all_images, &$width, &$height, &$count, &$clip` | 干预 Post 类 Thumbs 方法的接口 |
| [`Filter_Plugin_Post_Prev`](/php/dev-examples/magic/post-prev) | `$post` | Post 类的 Prev 接口 |
| [`Filter_Plugin_Post_Next`](/php/dev-examples/magic/post-next) | `$post` | Post 类的 Next 接口 |
| [`Filter_Plugin_Post_RelatedList`](/php/dev-examples/magic/post-related-list) | `$post` | Post 类的 RelatedList 接口 |
| [`Filter_Plugin_Post_CommentPostUrl`](/php/dev-examples/magic/post-comment-post-url) | `$post` | Post 类的 CommentPostUrl 接口 |

### 分类（Category）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Category_Url`](/php/dev-examples/magic/category-url) | `&$this` | 干预 Category 类 Url 方法的接口 |
| [`Filter_Plugin_Category_Get`](/php/dev-examples/magic/category-get) | `&$this, $method` | 干预 Category 类 Get 方法的接口 |
| [`Filter_Plugin_Category_Set`](/php/dev-examples/magic/category-set) | `&$this, $method, $arg` | 干预 Category 类 Set 方法的接口 |
| [`Filter_Plugin_Category_Save`](/php/dev-examples/magic/category-save) | `&$category` | Category 类的 Save 方法接口 |
| [`Filter_Plugin_Category_Del`](/php/dev-examples/magic/category-del) | `&$category` | Category 类的 Del 方法接口 |
| [`Filter_Plugin_Category_Call`](/php/dev-examples/magic/category-call) | `&$category, $method, $args` | Category 类的魔术方法接口 |

### 标签（Tag）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Tag_Url`](/php/dev-examples/magic/tag-url) | `&$this` | 干预 Tag 类 Url 方法的接口 |
| [`Filter_Plugin_Tag_Get`](/php/dev-examples/magic/tag-get) | `&$this, $method` | 干预 Tag 类 Get 方法的接口 |
| [`Filter_Plugin_Tag_Set`](/php/dev-examples/magic/tag-set) | `&$this, $method, $arg` | 干预 Tag 类 Set 方法的接口 |
| [`Filter_Plugin_Tag_Save`](/php/dev-examples/magic/tag-save) | `&$tag` | Tag 类的 Save 方法接口 |
| [`Filter_Plugin_Tag_Del`](/php/dev-examples/magic/tag-del) | `&$tag` | Tag 类的 Del 方法接口 |
| [`Filter_Plugin_Tag_Call`](/php/dev-examples/magic/tag-call) | `&$tag, $method, $args` | Tag 类的魔术方法接口 |

### 用户（Member）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Member_Url`](/php/dev-examples/magic/member-url) | `&$this` | 干预 Member 类 Url 方法的接口 |
| [`Filter_Plugin_Member_Get`](/php/dev-examples/magic/member-get) | `&$this, $method` | 干预 Member 类 Get 方法的接口 |
| [`Filter_Plugin_Member_Set`](/php/dev-examples/magic/member-set) | `&$this, $method, $arg` | 干预 Member 类 Set 方法的接口 |
| [`Filter_Plugin_Member_Save`](/php/dev-examples/magic/member-save) | `&$member` | Member 类的 Save 方法接口 |
| [`Filter_Plugin_Member_Del`](/php/dev-examples/magic/member-del) | `&$member` | Member 类的 Del 方法接口 |
| [`Filter_Plugin_Member_Call`](/php/dev-examples/magic/member-call) | `&$member, $method, $args` | Member 类的魔术方法接口 |
| [`Filter_Plugin_Member_Avatar`](/php/dev-examples/magic/member-avatar) | `$member` | Member 类的 Avatar 接口 |

### 评论（Comment）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Comment_Get`](/php/dev-examples/magic/comment-get) | `&$this, $method` | 干预 Comment 类 Get 方法的接口 |
| [`Filter_Plugin_Comment_Set`](/php/dev-examples/magic/comment-set) | `&$this, $method, $arg` | 干预 Comment 类 Set 方法的接口 |
| [`Filter_Plugin_Comment_Save`](/php/dev-examples/magic/comment-save) | `&$comment` | Comment 类的 Save 方法接口 |
| [`Filter_Plugin_Comment_Del`](/php/dev-examples/magic/comment-del) | `&$comment` | Comment 类的 Del 方法接口 |
| [`Filter_Plugin_Comment_Call`](/php/dev-examples/magic/comment-call) | `&$comment, $method, $args` | Comment 类的魔术方法接口 |

### 模块（Module）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Module_Get`](/php/dev-examples/magic/module-get) | `&$this, $method` | 干预 Module 类 Get 方法的接口 |
| [`Filter_Plugin_Module_Set`](/php/dev-examples/magic/module-set) | `&$this, $method, $arg` | 干预 Module 类 Set 方法的接口 |
| [`Filter_Plugin_Module_Save`](/php/dev-examples/magic/module-save) | `&$module` | Module 类的 Save 方法接口 |
| [`Filter_Plugin_Module_Del`](/php/dev-examples/magic/module-del) | `&$module` | Module 类的 Del 方法接口 |

### 附件（Upload）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Upload_SaveFile`](/php/dev-examples/magic/upload-save-file) | `$tmp, $this` | Upload 类的 SaveFile 方法接口 |
| [`Filter_Plugin_Upload_SaveBase64File`](/php/dev-examples/magic/upload-save-base64-file) | `$str64, $this` | Upload 类的 SaveBase64File 方法接口 |
| [`Filter_Plugin_Upload_Del`](/php/dev-examples/magic/upload-del) | `$this` | Upload 类的 Del 方法接口 |
| [`Filter_Plugin_Upload_DelFile`](/php/dev-examples/magic/upload-del-file) | `$this` | Upload 类的 DelFile 方法接口 |
| [`Filter_Plugin_Upload_Url`](/php/dev-examples/magic/upload-url) | `$upload` | Upload 类的 Url 方法接口 |
| [`Filter_Plugin_Upload_Get`](/php/dev-examples/magic/upload-get) | `&$this, $method` | 干预 Upload 类 Get 方法的接口 |
| [`Filter_Plugin_Upload_Set`](/php/dev-examples/magic/upload-set) | `&$this, $method, $arg` | 干预 Upload 类 Set 方法的接口 |
| [`Filter_Plugin_Upload_Dir`](/php/dev-examples/magic/upload-dir) | `$upload` | Upload 类的 Dir 方法接口 |

### 系统（Zbp）

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Zbp_Call`](/php/dev-examples/magic/zbp-call) | `$method, $args` | Zbp 类的魔术方法接口 |
| [`Filter_Plugin_Zbp_Get`](/php/dev-examples/magic/zbp-get) | `$name` | Zbp 类的魔术方法接口 |
| [`Filter_Plugin_Zbp_Set`](/php/dev-examples/magic/zbp-set) | `$name, $value` | Zbp 类的魔术方法接口 |
| [`Filter_Plugin_Zbp_CheckRights`](/php/dev-examples/magic/zbp-check-rights) | `$action` | Zbp 类的检查权限接口（检查当前用户） |

### 其他

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_GetPost_Result`](/php/dev-examples/magic/get-post-result) | `&$post` | 定义 GetPost 输出结果接口 |
| [`Filter_Plugin_GetList_Result`](/php/dev-examples/magic/get-list-result) | `&$list` | 定义 GetList 输出结果接口 |
| [`Filter_Plugin_App_Pack`](/php/dev-examples/magic/app-pack) | `$this, $this->dirs, $this->files` | App 类的 Pack 方法接口 |
| [`Filter_Plugin_DbSql_Filter`](/php/dev-examples/magic/db-sql-filter) | `$method, $args` | DbSql 类的 SQL 过滤和统计方法接口 |

## 「流程/事件」监听

### 指令提交

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Cmd_Begin`](/php/dev-examples/event/cmd-begin) | | cmd.php 的启动接口，可以在这里拦截各种 action |
| [`Filter_Plugin_Cmd_End`](/php/dev-examples/event/cmd-end) | | cmd.php 的结束接口，可以在这里拦截各种 action 之后的处理 |
| [`Filter_Plugin_Cmd_Ajax`](/php/dev-examples/event/cmd-ajax) | | cmd.php 的 Ajax 命令专用接口，插件需要自行判断权限 |
| [`Filter_Plugin_Cmd_Redirect`](/php/dev-examples/event/cmd-redirect) | `$url, $action` | cmd.php 的最后跳转接口，用于修改 url 跳转值 |
| [`Filter_Plugin_Misc_Begin`](/php/dev-examples/event/misc-begin) | `$type` | c_system_misc.php 的启动接口，可以在这里拦截各种 type |

### 登录验证

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_VerifyLogin_Succeed`](/php/dev-examples/event/verify-login-succeed) | | VerifyLogin 成功的接口 |
| [`Filter_Plugin_VerifyLogin_Failed`](/php/dev-examples/event/verify-login-failed) | | VerifyLogin 失败的接口 |
| [`Filter_Plugin_Logout_Succeed`](/php/dev-examples/event/logout-succeed) | | Logout 成功的接口 |
| [`Filter_Plugin_Login_Header`](/php/dev-examples/event/login-header) | | 定义 Login.php 首页 header 接口 |
| [`Filter_Plugin_Other_Header`](/php/dev-examples/event/other-header) | | 定义其它页的 header 接口 |

### 系统加载

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Zbp_PreLoad`](/php/dev-examples/event/zbp-pre-load) | | Zbp 类的预加载接口 |
| [`Filter_Plugin_Zbp_Load`](/php/dev-examples/event/zbp-load) | | Zbp 类的加载接口 |
| [`Filter_Plugin_Zbp_Load_Pre`](/php/dev-examples/event/zbp-load-pre) | | Zbp 类的加载（预处理）接口 |
| [`Filter_Plugin_Zbp_LoadManage`](/php/dev-examples/event/zbp-load-manage) | | Zbp 类的后台管理初始加载接口 |
| [`Filter_Plugin_Zbp_CheckSiteClosed`](/php/dev-examples/event/zbp-check-site-closed) | | Zbp 类的跳出关站检查接口 |
| [`Filter_Plugin_Zbp_Terminate`](/php/dev-examples/event/zbp-terminate) | | Zbp 类的终结接口 |
| `Filter_Plugin_Zbp_ShowError` | | 1.7.3 已废弃，请使用 `Filter_Plugin_Debug_Handler_Common` 接口，参数不变 |
| [`Filter_Plugin_Zbp_ShowValidCode`](/php/dev-examples/event/zbp-show-valid-code) | `$id` | Zbp 类的显示验证码接口，具有唯一性 |
| [`Filter_Plugin_Zbp_CheckValidCode`](/php/dev-examples/event/zbp-check-valid-code) | `$vaidcode, $id` | Zbp 类的比对验证码接口，具有唯一性 |

### 调试与日志

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| `Filter_Plugin_Debug_Handler` | | 1.7.3 已废弃，不应再使用 |
| [`Filter_Plugin_Debug_Handler_ZEE`](/php/dev-examples/event/debug-handler-zee) | `$zee, $debug_type` | 定义 Debug_Exception_Handler、Debug_Error_Handler 函数的接口 |
| [`Filter_Plugin_Debug_Handler_Common`](/php/dev-examples/event/debug-handler-common) | `int $errno, string $errstr, string $errfile, int $errline` | 这是 `Filter_Plugin_Zbp_ShowError` 接口的替代品，无须改动插件函数的参数 |
| [`Filter_Plugin_Debug_Display`](/php/dev-examples/event/debug-display) | `$zec` | 定义 ZBlogException 的 Display 函数的接口（与 Handler 不同的是一个传入 zbp 异常类一个是控制类） |
| [`Filter_Plugin_Autoload`](/php/dev-examples/event/autoload) | `$classname` | 监控 autoload 魔术方法 |
| [`Filter_Plugin_Logs`](/php/dev-examples/event/logs) | `$s, $iserror` | 监控记录函数 |
| [`Filter_Plugin_Http_Request_Convert_To_Global`](/php/dev-examples/event/http-request-convert-to-global) | `$request` | http_request_convert_to_global 函数 |

### 应用管理

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_EnablePlugin`](/php/dev-examples/event/enable-plugin) | `&$name` | EnablePlugin（1.6.0 加入） |
| [`Filter_Plugin_DisablePlugin`](/php/dev-examples/event/disable-plugin) | `&$name` | DisablePlugin（1.6.0 加入） |
| [`Filter_Plugin_BatchPost`](/php/dev-examples/event/batch-post) | `&$type` | BatchPost（1.6.1 加入） |

### 其他入口

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Xmlrpc_Begin`](/php/dev-examples/event/xmlrpc-begin) | `&$xml` | xml-rpc 页的 begin 接口（1.5.1 加入） |
| [`Filter_Plugin_CSP_Backend`](/php/dev-examples/event/csp-backend) | `&$xml` | 后台 CSP 接口（1.5.2 加入） |

### 大数据

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_LargeData_Article`](/php/dev-examples/event/large-data-article) | `&$select, &$where, &$order, &$limit, &$option` | 大数据文章接口 |
| [`Filter_Plugin_LargeData_Page`](/php/dev-examples/event/large-data-page) | `&$select, &$where, &$order, &$limit, &$option` | 大数据页面接口 |
| [`Filter_Plugin_LargeData_Comment`](/php/dev-examples/event/large-data-comment) | `&$select, &$where, &$order, &$limit, &$option` | 大数据评论接口 |
| [`Filter_Plugin_LargeData_CountTagArray`](/php/dev-examples/event/large-data-count-tag-array) | `$string, $plus, $articleid` | 大数据增减文章标签关联表 |
| [`Filter_Plugin_LargeData_GetList`](/php/dev-examples/event/large-data-get-list) | `&$select, &$where, &$order, &$limit, &$option` | 大数据 GetList 函数 |

### 后台其他

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Admin_Hint`](/php/dev-examples/event/admin-hint) | | 定义后台首页 hint 接口 |
| [`Filter_Plugin_Admin_Other_Action`](/php/dev-examples/event/admin-other-action) | | 后台管理页拦截后台管理请求实现自己的 Action |

### 前台其他

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_ViewPost_ViewNums`](/php/dev-examples/event/view-post-view-nums) | `&$article` | 定义 ViewPost 浏览数接口 |
| [`Filter_Plugin_ViewPost_Begin_V2`](/php/dev-examples/event/view-post-begin-v2) | `&$array` | 定义 POST 显示输出 begin 接口（第 2 版，只传入一个 $array） |
| [`Filter_Plugin_ViewList_Begin_V2`](/php/dev-examples/event/view-list-begin-v2) | `&$array` | 定义列表输出接口（第 2 版，只传一个 $array） |

## 「模板」处理

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [`Filter_Plugin_Template_Compiling_Begin`](/php/dev-examples/template/template-compiling-begin) | `$this, $content` | Template 类编译一个模板前的接口 |
| [`Filter_Plugin_Template_Compiling_End`](/php/dev-examples/template/template-compiling-end) | `$this, $content` | Template 类编译一个模板后的接口 |
| [`Filter_Plugin_Template_GetTemplate`](/php/dev-examples/template/template-get-template) | `$this, $name` | Template 类读取一个模板前的接口 |
| [`Filter_Plugin_Template_Display`](/php/dev-examples/template/template-display) | `$this, $entryPage` | Template 类显示接口 |
| [`Filter_Plugin_Zbp_BuildTemplate`](/php/dev-examples/template/zbp-build-template) | `$template` | Zbp 类的重新编译模板接口 |
| [`Filter_Plugin_Zbp_MakeTemplatetags`](/php/dev-examples/template/zbp-make-templatetags) | `$template` | Zbp 类的生成模板标签接口 |
| [`Filter_Plugin_Zbp_BuildModule`](/php/dev-examples/template/zbp-build-module) | | Zbp 类的生成模块内容的接口 |
| [`Filter_Plugin_Zbp_RegBuildModules`](/php/dev-examples/template/zbp-reg-build-modules) | | Zbp 类的注册模块时的接口 |
| [`Filter_Plugin_Zbp_PrepareTemplate`](/php/dev-examples/template/zbp-prepare-template) | `&$theme, &$template_dirname` | Zbp 类的 PrepareTemplate 接口 |
| [`Filter_Plugin_Html_Js_Add`](/php/dev-examples/template/html-js-add) | | c_html_js_add.php 脚本接口，允许插件在 c_html_js_add.php 内输出内容 |
| [`Filter_Plugin_Html_Js_ZbpConfig`](/php/dev-examples/template/html-js-zbp-config) | | c_html_js_add.php 脚本接口，允许插件设置 zbpConfig |
| [`Filter_Plugin_Admin_Js_Add`](/php/dev-examples/template/admin-js-add) | | c_admin_js_add.php 脚本页的接口 |
| [`Filter_Plugin_ViewExternalLink_Template`](/php/dev-examples/template/view-external-link-template) | `&$template` | 定义 ViewExternalLink 输出模板接口 |
| [`Filter_Plugin_OutputOptionItemsOfMemberLevel`](/php/dev-examples/template/output-option-items-of-member-level) | `$default, $tz` | 定义 OutputOptionItemsOfMemberLevel 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfMember_Begin`](/php/dev-examples/template/output-option-items-of-member-begin) | `$default, $posttype, $action, $tz` | 定义 OutputOptionItemsOfMember 函数里的前置接口 |
| [`Filter_Plugin_OutputOptionItemsOfCategories`](/php/dev-examples/template/output-option-items-of-categories) | `$default, $tz` | 定义 OutputOptionItemsOfCategories 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfPostStatus`](/php/dev-examples/template/output-option-items-of-post-status) | `$default, $tz` | 定义 OutputOptionItemsOfPostStatus 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfIsTop`](/php/dev-examples/template/output-option-items-of-is-top) | `$default, $tz` | 定义 OutputOptionItemsOfIsTop 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfMember`](/php/dev-examples/template/output-option-items-of-member) | `$default, $tz` | 定义 OutputOptionItemsOfMember 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfTemplate`](/php/dev-examples/template/output-option-items-of-template) | `$default, $tz` | 定义 OutputOptionItemsOfTemplate 函数里的接口 |
| [`Filter_Plugin_OutputOptionItemsOfCommon`](/php/dev-examples/template/output-option-items-of-common) | `$default, $array, $name` | 定义 OutputOptionItemsOfCommon 函数里的接口，因为是通用型的，所以有 $name |

## 「API」处理

| 接口 | 参数 | 说明 |
| --- | --- | --- |
| [Filter_Plugin_API_Begin](/php/dev-examples/api/begin) | | API 启动 |
| [Filter_Plugin_API_Dispatch](/php/dev-examples/api/dispatch) | `$mods, $mod, $act` | API 分发前 |
| [Filter_Plugin_API_Extend_Mods](/php/dev-examples/api/extend-mods) | | API 的应用追加模块机制 |
| [Filter_Plugin_API_CheckMods](/php/dev-examples/api/check-mods) | `&$mods_allow, &$mods_disallow` | API 的黑白名单机制 |
| [Filter_Plugin_API_Get_Request_Filter](/php/dev-examples/api/get-request-filter) | `&$condition` | API 获取约束过滤条件 |
| [Filter_Plugin_API_Get_Pagination_Info](/php/dev-examples/api/get-pagination-info) | `&$info, &$pagebar` | API 获取分页信息 |
| [Filter_Plugin_API_Get_Object_Array](/php/dev-examples/api/get-object-array) | `&$object, &$array, &$other_props, &$remove_props, &$with_relations` | API 转换 Object 到 Array |
| [Filter_Plugin_API_Post_List_Core](/php/dev-examples/api/post-list-core) | `&$select, $where, $order, $limit, $option` | 处理 api_post_list 的查询 |
| [Filter_Plugin_API_VerifyCSRF_Skip](/php/dev-examples/api/verify-csrf-skip) | `&$skip_acts` | API 校验 CSRF Token 跳过验证 |
| [Filter_Plugin_API_Result_Data](/php/dev-examples/api/result-data) | `&$result, $mod, $act` | 处理返回数据 |
| [Filter_Plugin_API_Pre_Response](/php/dev-examples/api/pre-response) | `&$data, &$error, &$code, &$message` | API 响应处理前接口 |
| [Filter_Plugin_API_Pre_Response_Raw](/php/dev-examples/api/pre-response-raw) | `&$raw, &$raw_type` | 处理返回数据 |
| [Filter_Plugin_API_Response](/php/dev-examples/api/response) | `&$response` | API 响应内容处理 |
