[WordPress] 外掛分享: Field block for ACF PRO

首頁外掛目錄 › Field block for ACF PRO
WordPress 外掛 Field block for ACF PRO 的封面圖片
20+
安裝啟用
尚無評分
730 天前
最後更新
問題解決
WordPress 6.2+ v1.3.1 上架:2024-03-13

內容簡介

**概要:**
ACF 欄位區塊顯示使用 ACF 註冊的個別欄位,支持多種欄位類型,包括基本、內容、選擇、關聯、進階和布局等。

**問題與答案:**
1. ACF 欄位區塊用於顯示什麼類型的數據?
- ACF 欄位區塊用於顯示使用 Advanced Custom Fields 註冊的個別欄位。

2. ACF 欄位區塊支持哪些欄位類型?
- 基本欄位類型包括文字、文字區域、數字、範圍、電子郵件、網址和密碼;內容包括圖片、檔案、所見即所得編輯器、oEmbed 和圖庫;選擇包括選擇、核取方塊、單選按鈕、按鈕組和是/否;關聯包括連結、文章對象、頁面連結、關係、分類和使用者;進階包括Google地圖、日期選擇器、日期時間選擇器、時間選擇器和顏色選擇器;布局包括群組、複製、重複者和靈活內容。

3. ACF 欄位區塊的特點有哪些?
- 使用單個區塊 ACF 欄位,可在查詢循環內使用,大多數欄位類型在區塊編輯器中呈現,支持顯示欄位標籤(如果需要)。

4. ACF 欄位區塊插件依賴於哪個插件?
- ACF 欄位區塊插件依賴 Advanced Custom Fields PRO;它使用插件的服務端渲染區塊邏輯。

5. 面向 PHP 開發人員的 ACF 欄位區塊的擴展架構是什麼?
- 可以通過字段類型覆蓋呈現邏輯、為自定義字段類型、自定義字段名稱提供呈現,並通過 hook 到 render_block_acf-field-block/acf-field 過濾器修改生成的 HTML 或用 acf_field_block_get_renderer 過濾器設置自己的回調函數/方法。

6. 使用 Google Map 欄位需要什麼?
- Google Map 欄位使用來自 maps.googleapis.com 的 JavaScript,需要一個 API 金鑰,可以從 https://developers.google.com/maps/documentation/javascript/get-api-key 獲取。

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.3.1) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Field block for ACF PRO」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

The ACF field block displays individual fields registered using ACF.
It supports the following field types:

Basic: Text, Text Area, Number, Range, Email, URL, Password
Content: Image, File, WYSIWYG Editor, oEmbed, Gallery
Choice: Select, Checkbox, Radio Button, Button Group, True / False
Relational: Link, Post Object, Page Link, Relationship, Taxonomy, User
Advanced: Google Map, Date Picker, Date Time Picker, Time Picker, Color Picker
Layout: Group, Clone, Repeater, Flexible Content

Features

Uses a single block – ACF field
The block can be used within the Query Loop
Most field types are rendered in the block editor.
Supports display of the field’s label, if required.

This plugin depends on Advanced Custom Fields PRO; it uses the plugin’s server side rendering block logic.
If ACF PRO is not activated then the ACF field block will not be registered.
For PHP developers
The extensible architecture allows:
– overrides to rendering logic by field type,
– rendering for custom field types,
– rendering for custom field names
If you want to alter the output from the acf-field-block/acf-field block
then you can either hook into the render_block_acf-field-block/acf-field filter to
modify the generated HTML,
or the acf_field_block_get_renderer filter to set your own callback function/method
for a field type or specific field.
Google Map fields use JavaScript from maps.googleapis.com.
The Google Map field requires an API key which you can obtain from
https://developers.google.com/maps/documentation/javascript/get-api-key

延伸相關外掛

文章
Filter
Apply Filters
Mastodon