前言介紹
- 這款 WordPress 外掛「iG:Custom Metaboxes」是 2015-02-23 上架。
- 目前有 10 個安裝啟用數。
- 上一次更新是 2015-02-24,距離現在已有 3722 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
- 外掛最低要求 WordPress 4.0 以上版本才可以安裝。
- 尚未有人給過這款外掛評分。
- 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。
外掛協作開發者
amit |
外掛標籤
meta | admin | library | metabox | custom field |
內容簡介
iG:Custom Metaboxes 是一個 WordPress 外掛,提供一個物件導向和整潔的 API,以在 wp-admin 的 post_type 新增/編輯螢幕上建立自訂 Meta box。
此外掛基本上是一個程式庫,旨在用於其他外掛或佈景主題。單獨使用此外掛將不會做任何事情,它沒有 UI,也沒有任何要設定/調整的配置。此外掛允許添加 HTML5 欄位,但是專用欄位的功能(如調色盤、日期選擇器等)取決於瀏覽器。此外掛不會添加任何 JavaScript 以使這些欄位與不支持 HTML5 或不添加專用欄位功能的瀏覽器兼容。
此外掛是以 WordPress.com VIP 合規性為基礎撰寫,因此即使您在 WordPress.com VIP 上託管您的網站,也可以直接使用此外掛。
需求:此外掛需要 PHP 5.4 或更高版本,並支援 WordPress 4.0 或更高版本。它可能在較低版本的 PHP 或 WordPress 上運作,但這些平台不提供任何支援。
歡迎在 Github 上提交拉取請求。
Github:https://github.com/coolamit/ig-custom-metaboxes
插件使用
單獨使用此外掛將不會做任何事情,它是一個程式庫,旨在用於其他外掛/佈景主題。它提供了一個面向對象的 API,以物件導向的方式在 wp-admin 的 post_type 螢幕上創建自訂 Meta box。
使用範例:
$metabox = new iG\Metabox\Metabox( 'my-metabox-1' );
$metabox->set_title( 'My Cool Metabox' )
->set_context( 'normal' )
->set_priority( 'default' )
->set_css_class( 'my-metabox' )
->set_post_type( 'post' )
->add_field( //添加一個簡單的文字輸入欄位
iG\Metabox\Text_Field::create( 'my-txt-1', 'My Text Field 1' )
->set_description( 'Some Desc for 1st Field' )
->set_css_class( 'my-txt-css-1 second-css-cls' )
->set_placeholder( 'Enter the first text here' )
->set_size( 50 )
)
->add_field( //添加一個 HTML5 數字輸入欄位
iG\Metabox\Number_Field::create( 'my-num-1', 'My Numb Field A' )
->set_description( 'Some Desc for 1st Number Field' )
->set_css_class( 'my-num-css-1' )
->set_placeholder( 'Enter the first number here' )
->set_step( 2.5 )
)
->add_field( //添加一個 HTML5 調色盤
iG\Metabox\Color_Field::create( 'my-col-1', 'My Color Field 1a' )
->set_description( 'Some Desc for 1st Color Field' )
->set_css_class( 'my-colr-css-1' )
)
->add_field( //添加一個 HTML 日期選擇器
iG\Metabox\Date_Field::create( 'my-dt-1', 'My Date Field 1a' )
->set_description( 'Some Desc for 1st Date Field' )
->set_css_class( 'my-dt-css-1' )
->set_min( '2014-05-01' )
)
->add_field( //添加一個 HTML5 日期時間選擇器
iG\Metabox\Date_Time_Field::create( 'my-dttm-1', 'My Date Time Field A' )
->set_description( 'Some Desc for 1st Date Time Field' )
->set_css_class( 'my-dttm-css-1' )
->set_min( '2014-05-01T05:00' )
)
->add_field( //添加一組單選按鈕
iG\Metabox\Radio_Group::create
原文外掛簡介
iG:Custom Metaboxes is a WordPress plugin to provide an object oriented and clean API for creating custom meta-boxes on wp-admin post_type add/edit screens.
This plugin is more or less a library which is meant to be used in other plugins or themes. On its own this plugin does nothing, it has no UI nor any configuration to be set/tweaked. This plugin allows addition of HTML5 fields however the functionality of specialized fields like color picker, date picker etc. is browser dependent. The plugin does not add any JavaScript to make these fields compatible with browsers which don’t support HTML5 or which don’t add functionality to these specialized fields.
This plugin has been written with WordPress.com VIP compliance in mind, so you can use it as is even if you host your website with WordPress.com VIP.
Requirements: This plugin requires PHP 5.4 or better and is supported on WordPress 4.0 or better. It might work on a lower version of PHP or WordPress but no support would be provided for those platforms.
Pull requests on Github are welcome.
Github: https://github.com/coolamit/ig-custom-metaboxes
Plugin Usage
On its own this plugin will not do anything, it is a library meant to be used in other plugins/themes. It provides an API to create custom metaboxes in wp-admin on post_type screens in an object oriented way.
Usage Example:
$metabox = new iG\Metabox\Metabox( 'my-metabox-1' );
$metabox->set_title( 'My Cool Metabox' )
->set_context( 'normal' )
->set_priority( 'default' )
->set_css_class( 'my-metabox' )
->set_post_type( 'post' )
->add_field( //add a simple text input field
iG\Metabox\Text_Field::create( 'my-txt-1', 'My Text Field 1' )
->set_description( 'Some Desc for 1st Field' )
->set_css_class( 'my-txt-css-1 second-css-cls' )
->set_placeholder( 'Enter the first text here' )
->set_size( 50 )
)
->add_field( //add a HTML5 number input field
iG\Metabox\Number_Field::create( 'my-num-1', 'My Numb Field A' )
->set_description( 'Some Desc for 1st Number Field' )
->set_css_class( 'my-num-css-1' )
->set_placeholder( 'Enter the first number here' )
->set_step( 2.5 )
)
->add_field( //add a HTML5 color picker
iG\Metabox\Color_Field::create( 'my-col-1', 'My Color Field 1a' )
->set_description( 'Some Desc for 1st Color Field' )
->set_css_class( 'my-colr-css-1' )
)
->add_field( //add a HTML date picker
iG\Metabox\Date_Field::create( 'my-dt-1', 'My Date Field 1a' )
->set_description( 'Some Desc for 1st Date Field' )
->set_css_class( 'my-dt-css-1' )
->set_min( '2014-05-01' )
)
->add_field( //add a HTML5 date time picker
iG\Metabox\Date_Time_Field::create( 'my-dttm-1', 'My Date Time Field A' )
->set_description( 'Some Desc for 1st Date Time Field' )
->set_css_class( 'my-dttm-css-1' )
->set_min( '2014-05-01T05:00' )
)
->add_field( //add a radio button group
iG\Metabox\Radio_Group::create( 'my-rdg-1', 'My Radio Group A' )
->set_description( 'Some Desc for 1st Radio Group' )
->set_css_class( 'my-rdg-css-1' )
->set_values( array(
'apple' => 'Apple',
'grape' => 'Grape',
'banana' => 'Banana',
'orange' => 'Orange',
'peach' => 'Peach',
) )
)
->add();
各版本下載點
- 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
- 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「iG:Custom Metaboxes」來進行安裝。
(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。
延伸相關外掛(你可能也想知道)
Redux Framework 》Redux – 快速在 WordPress 的 Gutenberg 中建立完整頁面, , 使用我們不斷更新的 WordPress 區塊模板、版面配置和模式強化 Gutenberg 編輯器。發現無限可能,...。
Loginizer 》Loginizer 是一個 WordPress 外掛,可幫助您對抗暴力攻擊,當 IP 地址達到最大重試次數時,該外掛會阻止其登錄。您可以使用 Loginizer 將 IP 地址列入黑名單...。
LightStart – Maintenance Mode, Coming Soon and Landing Page Builder 》這款 WordPress 外掛可讓您在維護網站時顯示一個維護頁面,讓訪客知道您的網站是暫時關閉的,也可以為新網站新增「即將到來」頁面,同時也可為現有網站創建登...。
Admin Menu Editor 》Admin Menu Editor 可讓您手動編輯儀表板菜單。您可以重新排序菜單,顯示/隱藏特定項目,修改權限等等。, 功能, , 更改菜單標題、URL、圖標、CSS 類等。, 通...。
White Label CMS 》White Label CMS 外掛針對開發者設計,提供客戶更具個性化且易於使用的內容管理系統。, 詳細瞭解 2.0 版本外掛變更,請參閱 Video User Manuals 網站。, 功能...。
Orbit Fox by ThemeIsle 》透過Orbit Fox,您可以使用各種模組擴充您的主題功能,例如社交媒體分享按鈕和圖示、自訂選單圖示、頁首和頁尾腳本、一鍵導入頁面模板、頁面建構器附加元件和...。
InfiniteWP Client 》InfiniteWP 可讓使用者從自己的伺服器管理無限數量的 WordPress 網站。, 主要功能:, , 自行託管系統:位於您自己的伺服器上,完全受您控制, 一鍵更新所有網站...。
Header and Footer Scripts 》如果您正在運行 WordPress 網站,早晚都需要將某種代碼插入到您的網站上。最有可能的是網頁分析代碼,例如 Google Analytics,或者是社交媒體腳本、某些 CSS ...。
Admin Columns 》這個 WordPress 外掛可以管理並整理文章、使用者、評論及媒體列表的欄位。它讓 WordPress 後台界面變得更美觀、明確。, , Admin Columns Pro, Admin Columns ...。
Nested Pages 》Nested Pages 是什麼?, , , 提供直覺且易於操作的拖放介面,以管理網頁結構及文章排序, 增強了快速編輯功能, 新增可編輯、可排序的樹狀表示網站頁面結構, 會...。
Disable REST API 》這是最全面的 WordPress REST API 存取控制外掛!, 輕鬆安裝,安裝後不需要額外設定即可使用。只需上傳並啟用,整個 REST API 將無法被一般訪客存取。, 但如...。
Advanced Custom Fields: Extended 》🚀 全方位增強套件,可改進WordPress和Advanced Custom Fields。此外掛旨在提供一個強大的管理框架,涵蓋了眾多改進和優化。, 此外掛需要至少 ACF Pro 5.8。,...。
Widget Shortcode 》這個短碼需要小工具的ID,但不需要猜測,外掛會為你生成代碼。如果你想要覆蓋小工具的標題,你可以使用 "title" 參數:, [widget id=”text-1″...。
All In One Favicon 》查看最新的WordPress交易以優化您的網站。, All In One Favicon為您的網站和管理頁面添加favicon。, 您可以使用您已經上傳的favicon或使用內置的上傳機制將fa...。
Add From Server 》這個外掛提供有限的支援。請不要期望有太多新功能或修正 bug。功能可能隨時被移除。, Add From Server 外掛旨在幫助緩解不好的網站主機所造成的困擾,讓您可...。