Portfolio X 3.8.2 has 27 actions and 203 filters, read directly from its source code on Nov 18, 2026. The list updates automatically when a new version is released.
How to use these hooks
Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.
// Run your own code when Portfolio X fires an action
add_action( 'cmb2_admin_init', function() {
// Your code runs here.
}, 10, 1 );
// Change a value Portfolio X is about to use
add_filter( 'ot_child_theme_mode', function( $value ) {
// Change $value here.
return $value;
}, 10, 1 );Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.
All hooks
-
/** * For developers: Child Theme mode. TODO document */ apply_filters( 'ot_child_theme_mode', false ); -
/** * Allows overloading the object (CMB2 or CMB2_Field) with additional * capabilities by registering hook callbacks. */ apply_filters_ref_array( "{$object_class}_inherit_{$method}", $args ); -
/** * Filter attributes for a field type. The dynamic portion of the hook name, * $element, refers to the field type. */ apply_filters( "cmb2_{$element}_attributes", $args, $type_defaults, $this->field, $this->types ); -
/** * Filter for determining if a field value has a valid image file-type * extension. */ apply_filters( "cmb2_{$this->field->id()}_is_valid_img_ext", $is_valid, $file, $file_ext ); -
/** * Fires before fields have been processed/saved. */ do_action( "cmb2_{$this->object_type()}_process_fields_{$this->cmb_id}", $this, $this->object_id() ); -
/** * Fires on the admin side when CMB2 is included/loaded. */ do_action( 'cmb2_admin_init' ); -
/** * Hook after form form has been rendered */ do_action( "cmb2_after_{$object_type}_form_{$this->cmb_id}", $object_id, $this ); -
/** * Hook after form form has been rendered */ do_action( 'cmb2_after_form', $this->cmb_id, $object_id, $object_type, $this ); -
/** * Fires after CMB2 initiation process has been completed */ do_action( 'cmb2_after_init' ); -
/** * By default, no special permissions needed. */ apply_filters( 'cmb2_api_get_boxes_permissions_check', true, $this ); -
/** * Hook before form table begins */ do_action( "cmb2_before_{$object_type}_form_{$this->cmb_id}", $object_id, $this ); -
/** * Hook before form table begins */ do_action( 'cmb2_before_form', $this->cmb_id, $object_id, $object_type, $this ); -
/** * Allow for adding additional HTML attributes to a group wrapper. */ apply_filters( 'cmb2_group_wrap_attributes', $group_wrap_attributes, $field_group ); -
/** * Fires when CMB2 is included/loaded */ do_action( 'cmb2_init' ); -
/** * Hook during initiation of CMB2 object */ do_action( "cmb2_init_{$this->cmb_id}", $this ); -
/** * Fires after all CMB2 instances are created */ do_action( 'cmb2_init_before_hookup' ); -
/** * Filter the CMB location url */ apply_filters( 'cmb2_meta_box_url', $cmb2_url, CMB2_VERSION ); -
/** * For back-compat. Does the dirty-work of instantiating all the CMB2 instances * for the cmb2_meta_boxes filter */ apply_filters( 'cmb2_meta_boxes', array() ); -
/** * Filter field types that are non-repeatable. */ apply_filters( 'cmb2_non_repeatable_fields', array() ); -
/** * Filter whether to override removing of meta value. */ apply_filters( "cmb2_override_{$a['field_id']}_meta_remove", $override, $a, $this->args(), $this ); -
/** * Filter and parameters are documented for 'cmb2_override_meta_save' filter * (above). */ apply_filters( "cmb2_override_{$a['field_id']}_meta_save", $override, $a, $this->args(), $this ); -
/** * Filter and parameters are documented for 'cmb2_override_meta_value' filter * (above). */ apply_filters( "cmb2_override_{$a['field_id']}_meta_value", $data, $this->object_id, $a, $this ); -
/** * Filter whether to override removing of meta value. Returning a non-null * value will effectively short-circuit the function. */ apply_filters( 'cmb2_override_meta_remove', null, $a, $this->args(), $this ); -
/** * Filter whether to override saving of meta value. Returning a non-null value * will effectively short-circuit the function. */ apply_filters( 'cmb2_override_meta_save', null, $a, $this->args(), $this ); -
/** * Filter whether to override getting of meta value. Returning a non * 'cmb2_field_no_override_val' value will effectively short-circuit the value * retrieval. */ apply_filters( 'cmb2_override_meta_value', 'cmb2_field_no_override_val', $this->object_id, $a, $this ); -
/** * A filter to bypass the default display. */ apply_filters( "cmb2_pre_field_display_{$this->type()}", null, $this, $display ); -
/** * Pass non-existent field types through an action. */ do_action( "cmb2_render_{$fieldtype}", $this->field, $this->field->escaped_value(), $this->field->object_id, $this->field->object_type, $this ); -
/** * Filters the custom field type class used for rendering the field. Class is * required to extend CMB2_Type_Base. */ apply_filters( "cmb2_render_class_{$fieldtype}", null, $this, $arguments ); -
/** * By default, 'text_url' and 'text' fields get table-like styling */ apply_filters( 'cmb2_repeat_table_row_types', array( 'text_url', 'text', ) ); -
/** * Filter the prepared CMB2 item response. */ apply_filters( 'cmb2_rest_prepare', rest_ensure_response( $data ), $this->request, $this ); -
/** * Globally filter row classes */ apply_filters( 'cmb2_row_classes', implode( ' ', $classes ), $this ); -
/** * Filter the value before it is saved. */ apply_filters( "cmb2_sanitize_{$this->type()}", null, $sanitizer->value, $this->object_id, $this->args(), $sanitizer ); -
/** * Fires after all fields have been saved. */ do_action( "cmb2_save_{$object_type}_fields", $object_id, $this->cmb_id, $this->updated, $this ); -
/** * Fires after all fields have been saved. */ do_action( "cmb2_save_{$object_type}_fields_{$this->cmb_id}", $object_id, $this->updated, $this ); -
/** * Hooks after save field action. */ do_action( 'cmb2_save_field', $field_id, $updated, $action, $this ); -
/** * Hooks after save field action. */ do_action( "cmb2_save_field_{$field_id}", $updated, $action, $this ); -
/** * Filter to determine if metabox should show. Default is true */ apply_filters( 'cmb2_show_on', $show, $this->cmb->meta_box, $this->cmb ); -
/** * Default (option-none) taxonomy-radio value. */ apply_filters( "cmb2_taxonomy_radio_{$field_id}_default_value", $option_none_value ); -
/** * Default (option-none) taxonomy-radio value. */ apply_filters( 'cmb2_taxonomy_radio_default_value', '' ); -
/** * Default (option-none) taxonomy-select value. */ apply_filters( "cmb2_taxonomy_select_{$field_id}_default_value", $option_none_value ); -
/** * Default (option-none) taxonomy-select value. */ apply_filters( 'cmb2_taxonomy_select_default_value', '' ); -
/** * Which image types are considered valid image file extensions. */ apply_filters( 'cmb2_valid_img_types', $valid_types ); -
/** * Globally filter box wrap classes */ apply_filters( 'cmb2_wrap_classes', $classes, $this ); -
/** * Fires when a deprecated argument is called. This is a WP core action. */ do_action( 'deprecated_argument_run', $function, $message, $version ); -
/** * Filters whether to trigger an error for deprecated arguments. This is a WP * core filter. */ apply_filters( 'deprecated_argument_trigger_error', true ); -
/** * For developers: Allow Unfiltered HTML in all the textareas. */ apply_filters( 'ot_allow_unfiltered_html', false ); -
/** * Filter the screen IDs used to dequeue `jquery-ui-css`. */ apply_filters( 'ot_dequeue_jquery_ui_css_screen_ids', array( 'toplevel_page_ot-settings', 'optiontree_page_ot-documentation', 'appearance_page_ot-theme-options' ) ); -
/** * Hook to insert arbitrary markup after the `do_settings_fields` method. */ do_action( 'ot_do_settings_fields_after', $page, $section_id ); -
/** * Hook to insert arbitrary markup before the `do_settings_fields` method. */ do_action( 'ot_do_settings_fields_before', $page, $section_id ); -
/** * Filter the `dynamic.css` fallback value. */ apply_filters( 'ot_insert_css_with_markers_fallback', $fallback, $option_id, $option_type, $option_key ); -
/** * Filter whether or not to enqueue a `dynamic.css` file at the theme level. */ apply_filters( 'ot_load_dynamic_css', true ); -
/** * For developers: Meta Boxes. */ apply_filters( 'ot_meta_boxes', true ); -
/** * Filter the label of the Off button. */ apply_filters( 'ot_on_off_switch_off_label', __( 'Off', 'portfolio-x' ), $field_id, 'off' ); -
/** * Filter the value of the Off button. */ apply_filters( 'ot_on_off_switch_off_value', 'off', $field_id, 'off' ); -
/** * Filter the label of the On button. */ apply_filters( 'ot_on_off_switch_on_label', __( 'On', 'portfolio-x' ), $field_id, 'on' ); -
/** * Filter the value of the On button. */ apply_filters( 'ot_on_off_switch_on_value', 'on', $field_id, 'on' ); -
/** * Filter the width of the On/Off switch. */ apply_filters( 'ot_on_off_switch_width', '100px', $field_id ); -
/** * For developers: Post Formats. */ apply_filters( 'ot_post_formats', false ); -
/** * Filter the post formats meta boxes. */ apply_filters( 'ot_recognized_post_format_meta_boxes', array( ot_meta_box_post_format_gallery(), ot_meta_box_post_format_link(), ot_meta_box_post_format_quote(), ot_meta_box_post_format_video(), ot_meta_box_post_format_audio(), ) ); -
/** * For developers: Show Documentation */ apply_filters( 'ot_show_docs', true ); -
/** * For developers: Show New Layout. */ apply_filters( 'ot_show_new_layout', true ); -
/** * For developers: Show Theme Options UI Builder */ apply_filters( 'ot_show_options_ui', true ); -
/** * For developers: Show Pages. */ apply_filters( 'ot_show_pages', true ); -
/** * For developers: Show Settings Export */ apply_filters( 'ot_show_settings_export', true ); -
/** * For developers: Show Settings Import */ apply_filters( 'ot_show_settings_import', true ); -
/** * For developers: Theme mode. */ apply_filters( 'ot_theme_mode', false ); -
/** * Use this filter to create a select instead of an text input. Be sure to * return the array in the correct format. Add an empty value to the first * choice so the user can leave it blank. */ apply_filters( 'ot_type_background_size_choices', '', $field_id ); -
/** * Filter the addition of the readonly attribute. */ apply_filters( 'ot_type_date_picker_readonly', false, $field_id ); -
/** * Filter the addition of the readonly attribute. */ apply_filters( 'ot_type_date_time_picker_readonly', false, $field_id ); -
/** * Filter the image attributes. */ apply_filters( 'ot_type_radio_image_attributes', '', $field_id, $choice ); -
/** * For developers: Custom Theme Option page */ apply_filters( 'ot_use_theme_options', true ); -
/** * Filter the post. */ apply_filters( 'rest_the_post', $post_obj, $post ); -
apply_filters( 'ot_theme_options_parent_slug', 'themes.php' ); -
apply_filters( 'ot_upload_text', __( 'Send to OptionTree', 'portfolio-x' ) ); -
apply_filters( 'plugin_install_action_links', $action_links, $plugin ); -
do_action( 'ot_before_theme_options_save', $options ); -
apply_filters_deprecated( "cmb2_validate_{$this->field->type()}", array( null, $this->value, $this->field->object_id, $this->field->args(), $this ), '2.0.0', "cmb2_sanitize_{$this->field->type()}" ); -
apply_filters( 'css_option_file_path', $filepath, $field_id ); -
apply_filters( 'ot_cleanup_page_title', __( 'OptionTree Cleanup', 'portfolio-x' ) ); -
apply_filters( 'ot_consolidate_posts_reload', 500 ); -
apply_filters( 'ot_override_forced_textarea_simple', false, $field['id'] ); -
apply_filters( 'ot_theme_options_capability', 'edit_theme_options' ); -
apply_filters( 'ot_theme_options_page_title', __( 'Theme Options', 'portfolio-x' ) ); -
apply_filters( 'ot_wpautop', false, $field_id ); -
apply_filters( 'ot_wpml_option_types', array( 'text', 'textarea', 'textarea-simple' ) ); -
apply_filters( "{ot_settings_id()}_args", $custom_settings ); -
apply_filters( 'cmb2_all_or_nothing_types', array( 'select', 'radio', 'radio_inline', 'taxonomy_select', 'taxonomy_radio', 'taxonomy_radio_inline' ), $this ); -
apply_filters( 'cmb2_can_save', ( $this->cmb->prop( 'save_fields' ) && isset( $_POST[ $this->cmb->nonce() ] ) && wp_verify_nonce( $_POST[ $this->cmb->nonce() ], $this->cmb->nonce() ) && ! ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) && ( $type && in_array( $type, $this->cmb->prop( 'object_types' ) ) ) && ! ( is_multisite() && ms_is_switched() ) ) ); -
apply_filters( 'cmb2_default_filter', $default, $this ); -
apply_filters( 'cmb2_enqueue_css', true ); -
apply_filters( 'cmb2_enqueue_js', true ); -
apply_filters( 'cmb2_get_metabox_form', $form, $object_id, $cmb ); -
apply_filters( 'cmb2_get_metabox_form_format', $args['form_format'], $object_id, $cmb ); -
apply_filters( 'cmb2_localized_data', $l10n ); -
apply_filters( "cmb2_override_option_get_{$this->key}", 'cmb2_no_override_option_get', $default, $this ); -
apply_filters( "cmb2_override_option_save_{$this->key}", 'cmb2_no_override_option_save', $this->options, $this ); -
apply_filters( 'cmb2_script_dependencies', self::$dependencies ); -
apply_filters( "cmb2_show_on_term_add_form_{$this->cmb->cmb_id}", $show_on_add, $this->cmb ); -
apply_filters( 'cmb2_style_dependencies', array() ); -
apply_filters( "cmb2_types_esc_{$this->type()}", null, $meta_value, $this->args(), $this ); -
apply_filters( 'image_slider_fields', array( array( 'name' => 'image', 'type' => 'image', 'label' => __( 'Image', 'portfolio-x' ), 'class' => '' ), array( 'name' => 'link', 'type' => 'text', 'label' => __( 'Link', 'portfolio-x' ), 'class' => '' ), array( 'name' => 'description', 'type' => 'textarea', 'label' => __( 'Description', 'portfolio-x' ), 'class' => '' ) ), $id ); -
apply_filters( 'measurement_unit_types', $array, $id ); -
apply_filters( 'oembed_ttl', DAY_IN_SECONDS, '', array(), 0 ); -
apply_filters( 'option_tree_option_types', $array ); -
do_action( 'ot_admin_scripts_after' ); -
do_action( 'ot_admin_scripts_before' ); -
do_action( 'ot_admin_styles_after' ); -
do_action( 'ot_admin_styles_before' ); -
do_action( 'ot_after_theme_options_save', $options ); -
apply_filters( 'ot_after_validate_setting', $input, $type, $field_id ); -
apply_filters( 'ot_before_page_messages', '', $page ); -
do_action( 'ot_custom_page_messages', $page ); -
apply_filters( 'ot_display_by_type', $args ); -
apply_filters( 'ot_filter_description', ( isset( $desc ) ? $desc : '' ), $id ); -
apply_filters( 'ot_font_size_high_range', 150, $field_id ); -
apply_filters( 'ot_font_size_low_range', 0, $field_id ); -
apply_filters( 'ot_font_size_range_interval', 1, $field_id ); -
apply_filters( 'ot_font_size_unit_type', 'px', $field_id ); -
apply_filters( 'ot_google_font_stack', $font_stack, $family, $field_id ); -
apply_filters( 'ot_google_fonts_api_key', 'AIzaSyB8G-4UtQr9fhDYTiNrDP40Y5GYQQKrNWI' ); -
apply_filters( 'ot_google_fonts_api_url', 'https://www.googleapis.com/webfonts/v1/webfonts' ); -
apply_filters( 'ot_google_fonts_cache', get_transient( $ot_google_fonts_cache_key ) ); -
apply_filters( 'ot_google_fonts_cache_key', 'ot_google_fonts_cache' ); -
apply_filters( 'ot_google_fonts_fields', array( 'family', 'variants', 'subsets' ) ); -
apply_filters( 'ot_google_fonts_sort', 'alpha' ); -
do_action( 'ot_header_list', $page['id'] ); -
apply_filters( 'ot_header_logo_link', '<a href="http://wordpress.org/extend/plugins/option-tree/" target="_blank">OptionTree</a>', $page['id'] ); -
apply_filters( 'ot_header_version_text', 'OptionTree ' . OT_VERSION, $page['id'] ); -
apply_filters( 'ot_insert_css_with_markers_bg_size_white_space', "\n\x20\x20", $option_id ); -
apply_filters( 'ot_insert_css_with_markers_value', $value, $option_id ); -
apply_filters( 'ot_layouts_id', 'option_tree_layouts' ); -
apply_filters( 'ot_letter_spacing_high_range', 0.1, $field_id ); -
apply_filters( 'ot_letter_spacing_low_range', -0.1, $field_id ); -
apply_filters( 'ot_letter_spacing_range_interval', 0.01, $field_id ); -
apply_filters( 'ot_letter_spacing_unit_type', 'em', $field_id ); -
apply_filters( 'ot_line_height_high_range', 150, $field_id ); -
apply_filters( 'ot_line_height_low_range', 0, $field_id ); -
apply_filters( 'ot_line_height_range_interval', 1, $field_id ); -
apply_filters( 'ot_line_height_unit_type', 'px', $field_id ); -
apply_filters( 'ot_list_item_description', $list_desc, $field_id ); -
apply_filters( 'ot_list_item_settings', array( array( 'id' => 'image', 'label' => __( 'Image', 'portfolio-x' ), 'desc' => '', 'std' => '', 'type' => 'upload', 'rows' => '', 'class' => '', 'post_type' => '', 'choices' => array() ), array( 'id' => 'link', 'label' => __( 'Link', 'portfolio-x' ), 'desc' => '', 'std' => '', 'type' => 'text', 'rows' => '', 'class' => '', 'post_type' => '', 'choices' => array() ), array( 'id' => 'descriptio... ); -
apply_filters( 'ot_list_item_title_desc', $field['desc'], $name ); -
apply_filters( 'ot_list_item_title_label', $field['label'], $name ); -
apply_filters( 'ot_measurement_unit_types', array( 'px' => 'px', '%' => '%', 'em' => 'em', 'pt' => 'pt' ), $field_id ); -
apply_filters( 'ot_media_buttons', true, $field_id ); -
apply_filters( 'ot_meta_box_post_format_audio', array( 'id' => 'ot-post-format-audio', 'title' => __( 'Audio', 'portfolio-x' ), 'desc' => '', 'pages' => $pages, 'context' => 'side', 'priority' => 'low', 'fields' => array( array( 'id' => '_format_audio_embed', 'label' => '', 'desc' => sprintf( __( 'Embed audio from services like SoundCloud and Rdio. You can find a list of supported oEmbed sites in the %1$s. Alternatively, you could use the bu... ); -
apply_filters( 'ot_meta_box_post_format_gallery', array( 'id' => 'ot-post-format-gallery', 'title' => __( 'Gallery', 'portfolio-x' ), 'desc' => '', 'pages' => $pages, 'context' => 'side', 'priority' => 'low', 'fields' => array( array( 'id' => '_format_gallery', 'label' => '', 'desc' => '', 'std' => '', 'type' => 'gallery', 'class' => 'ot-gallery-shortcode' ) ) ), $pages ); -
apply_filters( 'ot_meta_box_post_format_link', array( 'id' => 'ot-post-format-link', 'title' => __( 'Link', 'portfolio-x' ), 'desc' => '', 'pages' => $pages, 'context' => 'side', 'priority' => 'low', 'fields' => array( array( 'id' => '_format_link_url', 'label' => '', 'desc' => __( 'Link URL', 'portfolio-x' ), 'std' => '', 'type' => 'text' ), array( 'id' => '_format_link_title', 'label' => '', 'desc' => __( 'Link Title', 'portfolio-x' ), 's... ); -
apply_filters( 'ot_meta_box_post_format_quote', array( 'id' => 'ot-post-format-quote', 'title' => __( 'Quote', 'portfolio-x' ), 'desc' => '', 'pages' => $pages, 'context' => 'side', 'priority' => 'low', 'fields' => array( array( 'id' => '_format_quote_source_name', 'label' => '', 'desc' => __( 'Source Name (ex. author, singer, actor)', 'portfolio-x' ), 'std' => '', 'type' => 'text' ), array( 'id' => '_format_quote_source_url', 'label' => '',... ); -
apply_filters( 'ot_meta_box_post_format_video', array( 'id' => 'ot-post-format-video', 'title' => __( 'Video', 'portfolio-x' ), 'desc' => '', 'pages' => $pages, 'context' => 'side', 'priority' => 'low', 'fields' => array( array( 'id' => '_format_video_embed', 'label' => '', 'desc' => sprintf( __( 'Embed video from services like Youtube, Vimeo, or Hulu. You can find a list of supported oEmbed sites in the %1$s. Alternatively, you could use th... ); -
apply_filters( 'ot_migrate_layouts_id', '' ); -
apply_filters( 'ot_migrate_options_id', '' ); -
apply_filters( 'ot_migrate_settings_id', '' ); -
apply_filters( 'ot_option_types_array', array( 'background' => __('Background', 'portfolio-x'), 'border' => __('Border', 'portfolio-x'), 'box-shadow' => __('Box Shadow', 'portfolio-x'), 'category-checkbox' => __('Category Checkbox', 'portfolio-x'), 'category-select' => __('Category Select', 'portfolio-x'), 'checkbox' => __('Checkbox', 'portfolio-x'), 'colorpicker' => __('Colorpicker', 'portfolio-x'), 'colorpicker-opacity' => __('Colo... ); -
apply_filters( 'ot_options_id', 'option_tree' ); -
do_action( 'ot_pre_consolidate_posts' ); -
apply_filters( 'ot_quicktags', array( 'buttons' => 'strong,em,link,block,del,ins,img,ul,ol,li,code,spell,close' ), $field_id ); -
apply_filters( 'ot_radio_images', array( array( 'value' => 'left-sidebar', 'label' => __( 'Left Sidebar', 'portfolio-x' ), 'src' => OT_URL . 'assets/images/layout/left-sidebar.png' ), array( 'value' => 'right-sidebar', 'label' => __( 'Right Sidebar', 'portfolio-x' ), 'src' => OT_URL . 'assets/images/layout/right-sidebar.png' ), array( 'value' => 'full-width', 'label' => __( 'Full Width (no sidebar)', 'portfolio-x' ), 'src' => O... ); -
apply_filters( 'ot_recognized_background_attachment', array( "fixed" => "Fixed", "scroll" => "Scroll", "inherit" => "Inherit" ), $field_id ); -
apply_filters( 'ot_recognized_background_fields', array( 'background-color', 'background-repeat', 'background-attachment', 'background-position', 'background-size', 'background-image' ), $field_id ); -
apply_filters( 'ot_recognized_background_position', array( "left top" => "Left Top", "left center" => "Left Center", "left bottom" => "Left Bottom", "center top" => "Center Top", "center center" => "Center Center", "center bottom" => "Center Bottom", "right top" => "Right Top", "right center" => "Right Center", "right bottom" => "Right Bottom" ), $field_id ); -
apply_filters( 'ot_recognized_background_repeat', array( 'no-repeat' => 'No Repeat', 'repeat' => 'Repeat All', 'repeat-x' => 'Repeat Horizontally', 'repeat-y' => 'Repeat Vertically', 'inherit' => 'Inherit' ), $field_id ); -
apply_filters( 'ot_recognized_border_fields', array( 'width', 'unit', 'style', 'color' ), $field_id ); -
apply_filters( 'ot_recognized_border_style_types', array( 'hidden' => 'Hidden', 'dashed' => 'Dashed', 'solid' => 'Solid', 'double' => 'Double', 'groove' => 'Groove', 'ridge' => 'Ridge', 'inset' => 'Inset', 'outset' => 'Outset', ), $field_id ); -
apply_filters( 'ot_recognized_border_unit_types', array( 'px' => 'px', '%' => '%', 'em' => 'em', 'pt' => 'pt' ), $field_id ); -
apply_filters( 'ot_recognized_box_shadow_fields', array( 'inset', 'offset-x', 'offset-y', 'blur-radius', 'spread-radius', 'color' ), $field_id ); -
apply_filters( 'ot_recognized_dimension_fields', array( 'width', 'height', 'unit' ), $field_id ); -
apply_filters( 'ot_recognized_dimension_unit_types', array( 'px' => 'px', '%' => '%', 'em' => 'em', 'pt' => 'pt' ), $field_id ); -
apply_filters( 'ot_recognized_font_families', $families, $field_id ); -
apply_filters( 'ot_recognized_font_sizes', $range, $field_id ); -
apply_filters( 'ot_recognized_font_styles', array( 'normal' => 'Normal', 'italic' => 'Italic', 'oblique' => 'Oblique', 'inherit' => 'Inherit' ), $field_id ); -
apply_filters( 'ot_recognized_font_variants', array( 'normal' => 'Normal', 'small-caps' => 'Small Caps', 'inherit' => 'Inherit' ), $field_id ); -
apply_filters( 'ot_recognized_font_weights', array( 'normal' => 'Normal', 'bold' => 'Bold', 'bolder' => 'Bolder', 'lighter' => 'Lighter', '100' => '100', '200' => '200', '300' => '300', '400' => '400', '500' => '500', '600' => '600', '700' => '700', '800' => '800', '900' => '900', 'inherit' => 'Inherit' ), $field_id ); -
apply_filters( 'ot_recognized_google_font_families', $families, $field_id ); -
apply_filters( 'ot_recognized_google_font_fields', array( 'variants', 'subsets' ), $field_id ); -
apply_filters( 'ot_recognized_google_font_subsets', $subsets, $field_id, $family ); -
apply_filters( 'ot_recognized_google_font_variants', $variants, $field_id, $family ); -
apply_filters( 'ot_recognized_letter_spacing', $range, $field_id ); -
apply_filters( 'ot_recognized_line_heights', $range, $field_id ); -
apply_filters( 'ot_recognized_link_color_fields', array( 'link' => _x( 'Standard', 'color picker', 'portfolio-x' ), 'hover' => _x( 'Hover', 'color picker', 'portfolio-x' ), 'active' => _x( 'Active', 'color picker', 'portfolio-x' ), 'visited' => _x( 'Visited', 'color picker', 'portfolio-x' ), 'focus' => _x( 'Focus', 'color picker', 'portfolio-x' ) ), $field_id ); -
apply_filters( 'ot_recognized_sidebars', $sidebars ); -
apply_filters( "ot_recognized_sidebars_{$field_id}", $sidebars ); -
apply_filters( 'ot_recognized_spacing_fields', array( 'top', 'right', 'bottom', 'left', 'unit' ), $field_id ); -
apply_filters( 'ot_recognized_spacing_unit_types', array( 'px' => 'px', '%' => '%', 'em' => 'em', 'pt' => 'pt' ), $field_id ); -
apply_filters( 'ot_recognized_text_decorations', array( 'blink' => 'Blink', 'inherit' => 'Inherit', 'line-through' => 'Line Through', 'none' => 'None', 'overline' => 'Overline', 'underline' => 'Underline' ), $field_id ); -
apply_filters( 'ot_recognized_text_transformations', array( 'capitalize' => 'Capitalize', 'inherit' => 'Inherit', 'lowercase' => 'Lowercase', 'none' => 'None', 'uppercase' => 'Uppercase' ), $field_id ); -
apply_filters( 'ot_recognized_typography_fields', array( 'font-color', 'font-family', 'font-size', 'font-style', 'font-variant', 'font-weight', 'letter-spacing', 'line-height', 'text-decoration', 'text-transform' ), $field_id ); -
apply_filters( 'ot_register_pages_array', $ot_register_pages_array ); -
apply_filters( 'ot_settings_id', 'option_tree_settings' ); -
apply_filters( 'ot_social_links_description', __( 'You can re-order with drag & drop, the order will update after saving.', 'portfolio-x' ), $field_id ); -
apply_filters( 'ot_social_links_settings', array( array( 'id' => 'name', 'label' => __( 'Name', 'portfolio-x' ), 'desc' => __( 'Enter the name of the social website.', 'portfolio-x' ), 'std' => '', 'type' => 'text', 'class' => 'option-tree-setting-title' ), array( 'id' => 'title', 'label' => 'Title', 'desc' => __( 'Enter the text shown in the title attribute of the link.', 'portfolio-x' ), 'type' => 'text' ), array( 'id' => 'href', 'lab... ); -
apply_filters( 'ot_theme_options_button_text', __( 'Save Changes', 'portfolio-x' ) ); -
apply_filters( 'ot_theme_options_contextual_help', $contextual_help ); -
apply_filters( 'ot_theme_options_icon_url', null ); -
apply_filters( 'ot_theme_options_position', null ); -
apply_filters( 'ot_theme_options_reset_message', __( 'Theme Options reset.', 'portfolio-x' ) ); -
apply_filters( 'ot_theme_options_sections', $sections ); -
apply_filters( 'ot_theme_options_settings', $settings ); -
apply_filters( 'ot_theme_options_updated_message', __( 'Theme Options updated.', 'portfolio-x' ) ); -
apply_filters( 'ot_tinymce', true, $field_id ); -
apply_filters( 'ot_type_category_checkbox_query', array( 'hide_empty' => false ), $field_id ); -
apply_filters( 'ot_type_category_select_query', array( 'hide_empty' => false ), $field_id ); -
apply_filters( 'ot_type_custom_post_type_checkbox_query', array( 'post_type' => $post_type, 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_custom_post_type_select_query', array( 'post_type' => $post_type, 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_date_picker_date_format', 'yy-mm-dd', $field_id ); -
apply_filters( 'ot_type_date_time_picker_date_format', 'yy-mm-dd', $field_id ); -
apply_filters( 'ot_type_page_checkbox_query', array( 'post_type' => array( 'page' ), 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_page_select_query', array( 'post_type' => array( 'page' ), 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_post_checkbox_query', array( 'post_type' => array( 'post' ), 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_post_select_query', array( 'post_type' => array( 'post' ), 'posts_per_page' => -1, 'orderby' => 'title', 'order' => 'ASC', 'post_status' => 'any' ), $field_id ); -
apply_filters( 'ot_type_radio_image_src', $src, $field_id ); -
apply_filters( 'ot_type_select_choices', $field_choices, $field_id ); -
apply_filters( 'ot_type_social_links_defaults', array( array( 'name' => __( 'Facebook', 'portfolio-x' ), 'title' => '', 'href' => '' ), array( 'name' => __( 'Twitter', 'portfolio-x' ), 'title' => '', 'href' => '' ), array( 'name' => __( 'Google+', 'portfolio-x' ), 'title' => '', 'href' => '' ), array( 'name' => __( 'LinkedIn', 'portfolio-x' ), 'title' => '', 'href' => '' ), array( 'name' => __( 'Pinterest', 'portfolio-x' ), 'title' => '', 'h... ); -
apply_filters( 'ot_type_social_links_load_defaults', true, $field_id ); -
apply_filters( 'ot_type_taxonomy_checkbox_query', array( 'hide_empty' => false, 'taxonomy' => $taxonomy ), $field_id ); -
apply_filters( 'ot_type_taxonomy_select_query', array( 'hide_empty' => false, 'taxonomy' => $taxonomy ), $field_id ); -
apply_filters( 'ot_validate_setting', $input, $type, $field_id ); -
apply_filters( 'plugin_locale', get_locale(), 'cmb2' ); -
apply_filters( 'recognized_background_position', $array, $id ); -
apply_filters( 'recognized_background_repeat', $array, $id ); -
apply_filters( 'recognized_font_families', $array, $id ); -
apply_filters( 'recognized_font_styles', $array, $id ); -
apply_filters( 'recognized_font_variants', $array, $id ); -
apply_filters( 'recognized_font_weights', $array, $id ); -
apply_filters( 'widget_title', $instance['title'] ); -
apply_filters( "wpbot_form_text_{esc_attr($this->plugin_name)}", $form );
Generated from Portfolio X's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.
Done for you
Rather have it built for you?
Tell us what should change and we’ll write and test the code using these hooks.
Custom hook snippet
from $49
A small, update-safe change built on the plugin’s own hooks.
- Code written against the plugin’s actions and filters
- Tested on a staging copy of your site
- Install instructions included
Typical turnaround: 2–3 business days
Choose thisPlugin customisation
from $149
New features or changed behaviour, without editing the plugin’s files.
- Built as a companion plugin, so updates never wipe it
- Exact quote before we start
- Tested on staging, then deployed
Typical turnaround: 3–7 business days
Choose thisNot sure which fits? Describe what you need and we’ll suggest the simplest option.
Can't find the right hook?
We can build the customisation for you. Describe what you need: