Class AdminPageFramework_MetaBox
Provides methods for creating meta boxes for post types.
Hooks
The class automatically creates WordPress action and filter hooks associated with the class methods. The class methods corresponding to the name of the below actions and filters can be extended to modify the page output. Those methods are the callbacks of the filters and actions.
Methods and Action Hooks
- start_{instantiated class name} – triggered at the end of the class constructor. This receives the class object in the first parameter.
- set_up_{instantiated class name} – triggered after the setUp() method is called. This receives the class object in the first parameter.
- do_{instantiated class name} – triggered when the meta box gets rendered. The first parameter: the calss object[3.1.3+].
Methods and Filter Hooks
- field_types_{instantiated class name} – receives the field type definition array. The first parameter: the field type definition array.
- field_{instantiated class name}_{field ID} – receives the form input field output of the given input field ID. The first parameter: output string. The second parameter: the array of option.
- content_{instantiated class name} – receives the entire output of the meta box. The first parameter: the output HTML string.
- style_common_{instantiated class name} – receives the output of the base CSS rules applied to the pages of the associated post types with the meta box.
- style_ie_common_{instantiated class name} – receives the output of the base CSS rules for Internet Explorer applied to the pages of the associated post types with the meta box.
- style_{instantiated class name} – receives the output of the CSS rules applied to the pages of the associated post types with the meta box.
- style_ie_{instantiated class name} – receives the output of the CSS rules for Internet Explorer applied to the pages of the associated post types with the meta box.
- script_common_{instantiated class name} – receives the output of the base JavaScript scripts applied to the pages of the associated post types with the meta box.
- script_{instantiated class name} – receives the output of the JavaScript scripts applied to the pages of the associated post types with the meta box.
- validation_{instantiated class name} – receives the form submission values as array. The first parameter: submitted input array. The second parameter: the original array stored in the database.
Remarks
The slugs must not contain a dot(.) or a hyphen(-) since it is used in the callback method name.
- AdminPageFramework_Factory_Router
-
AdminPageFramework_Factory_Model
-
AdminPageFramework_Factory_View
-
AdminPageFramework_Factory_Controller
-
AdminPageFramework_Factory
-
AdminPageFramework_MetaBox_Base
-
AdminPageFramework_MetaBox
Package: AdminPageFramework\MetaBox
Since: 2.0.0
Use: AdminPageFramework_Utility
Use: AdminPageFramework_Message
Use: AdminPageFramework_Debug
Use: AdminPageFramework_Property_MetaBox
Located at factory/AdminPageFramework_MetaBox/AdminPageFramework_MetaBox.php
Methods summary
public
|
#
__construct( string $sMetaBoxID, string $sTitle, string|array $asPostTypeOrScreenID = array( 'post' ), string $sContext = 'normal', string $sPriority = 'default', string $sCapability = 'edit_posts', string $sTextDomain = 'admin-page-framework' )
|
public
|
|
public
|
#
enqueueStyles( mixed $aSRCs, mixed $aPostTypes = array(), mixed $aCustomArgs = array() )
|
public
string
|
#
enqueueStyle( string $sSRC, array $aPostTypes = array(), array $aCustomArgs = array() )
|
public
|
#
enqueueScripts( mixed $aSRCs, mixed $aPostTypes = array(), mixed $aCustomArgs = array() )
|
public
string
|
#
enqueueScript( string $sSRC, string $aPostTypes = array(), string $aCustomArgs = array() )
|
Methods inherited from AdminPageFramework_MetaBox_Base
_getInputArray()
,
_getSavedMetaArray()
,
_isInstantiatable()
,
_replyToAddMetaBox()
,
_replyToDetermineToLoad()
,
_replyToGetSectionHeaderOutput()
,
_replyToPrintMetaBoxContents()
,
_replyToRegisterFormElements()
,
_replyToSaveMetaBoxFields()
,
_setOptionArray()
Methods inherited from AdminPageFramework_Factory_Controller
addHelpText()
,
addSettingField()
,
addSettingFields()
,
addSettingSection()
,
addSettingSections()
,
hasSettingNotice()
,
setFieldErrors()
,
setSettingNotice()
,
start()
Methods inherited from AdminPageFramework_Factory_View
_replyToGetFieldOutput()
,
_replyToPrintSettingNotice()
Methods inherited from AdminPageFramework_Factory_Model
_getFieldErrors()
,
_isValidationErrors()
,
_loadDefaultFieldTypeDefinitions()
,
_registerFields()
,
_replyToDeleteFieldErrors()
,
_replyToSaveFieldErrors()
,
_replyToSaveNotices()
,
_setUp()
Methods inherited from AdminPageFramework_Factory_Router
__call()
,
__get()
,
_getFormInstance()
,
_getHeadTagInstance()
,
_getHelpPaneInstance()
,
_getLinkInstancce()
,
_getPageLoadInfoInstance()
,
_isInThePage()
,
_replyToLoadComponents()
Magic methods summary
Properties summary
Properties inherited from AdminPageFramework_MetaBox_Base
$_sFieldsType
,
$_sTargetSectionTabSlug
Properties inherited from AdminPageFramework_Factory_Router
$oProp