Documentation
Documentation
Graphic_Data_Instance_Type
in package
Register class that defines the Instance Type functions
Table of Contents
Methods
- add_instance_type_admin_menu() : void
- Add the Instance Types admin menu item.
- instance_settings_init() : void
- Register the instance settings group and settings section.
- register_instance_type_navbar_name_meta() : void
- Register the 'navbar_name' meta field for the 'instance_type' taxonomy.
- register_instance_type_order_meta() : void
- Register the 'instance_order' meta field for the 'instance_type' taxonomy.
- register_instance_type_taxonomy() : void
- Register the 'instance_type' custom taxonomy if it does not already exist.
- render_instance_type_admin_page() : void
- Render the Instance Type taxonomy admin page.
Methods
add_instance_type_admin_menu()
Add the Instance Types admin menu item.
public
add_instance_type_admin_menu() : void
Registers a top-level WordPress admin menu page for managing instance types. Requires the 'manage_categories' capability.
instance_settings_init()
Register the instance settings group and settings section.
public
instance_settings_init() : void
Registers the 'instance_settings' option under the 'theme_settings_group' and adds a settings section for the instance configuration page.
Tags
register_instance_type_navbar_name_meta()
Register the 'navbar_name' meta field for the 'instance_type' taxonomy.
public
register_instance_type_navbar_name_meta() : void
Registers a meta field used to store the navigation bar display name for each instance type. The field is exposed in the REST API.
Tags
register_instance_type_order_meta()
Register the 'instance_order' meta field for the 'instance_type' taxonomy.
public
register_instance_type_order_meta() : void
Registers an integer meta field used to control the display order of instance types. The field is exposed in the REST API and sanitized with absint.
Tags
register_instance_type_taxonomy()
Register the 'instance_type' custom taxonomy if it does not already exist.
public
register_instance_type_taxonomy() : void
Registers a flat (non-hierarchical) taxonomy with admin UI support, an admin column, query var support, and a custom rewrite slug.
Tags
render_instance_type_admin_page()
Render the Instance Type taxonomy admin page.
public
render_instance_type_admin_page() : void
Handles POST submissions for adding, editing, and deleting instance_type taxonomy terms (including custom meta fields 'instance_order' and 'instance_navbar_name'), then outputs the management interface with an add form, existing terms table, and a hidden edit form toggled via JavaScript.