Bricks 中文文档:bricks_after_footer

📄 原始资料  |  展开查看原始 JSON(bricks_after_footer.json){ “name”: “bricks_after_footer”, “kind”: “action”, “url”: “https://academy.bricksbuilder.io/developer/hooks/actions/bricks-after_footer/”, “scraped_at”: “2026-08-29”, “hook_name”: “bricks_after_footer”, “description”: { “en”: “Runs after Bric…

📄 原始资料  |  展开查看原始 JSON(bricks_after_footer.json)
{
  "name": "bricks_after_footer",
  "kind": "action",
  "url": "https://academy.bricksbuilder.io/developer/hooks/actions/bricks-after_footer/",
  "scraped_at": "2026-08-29",
  "hook_name": "bricks_after_footer",
  "description": {
    "en": "Runs after Bricks renders the footer and before the site wrapper closes. Use it when custom output needs to appear immediately after the footer template.",
    "zh": "在 Bricks 渲染页脚之后、站点包装器关闭之前触发。当自定义输出需要紧跟页脚模板之后显示时使用。"
  },
  "example_usage": "add_action( 'bricks_after_footer', function() {\n    echo '<div class=\"after-footer-note\">Footer add-on output</div>';\n} );"
}

前言

在 Bricks 渲染页脚之后、站点包装器关闭之前触发。当自定义输出需要紧跟页脚模板之后显示时使用。

用法

将代码加入子主题的 functions.php

add_action( 'bricks_after_footer', function() {
    echo '';
} );

示例代码

官方示例用法

add_action( 'bricks_after_footer', function() {
    echo '';
} );

补充说明

更多细节可参考 官方文档