Astra_Meta_Boxes::custom_fields_support( array|mixed $args, string $post_type )

Register Post Meta options support.


Description


Parameters

$args

(array|mixed) (Required) the post type args.

$post_type

(string) (Required) the post type.


Source

File: inc/metabox/class-astra-meta-boxes.php

		public function custom_fields_support( $args, $post_type ) {
			if ( is_array( $args ) && isset( $args['public'] ) && $args['public'] && isset( $args['supports'] ) && is_array( $args['supports'] ) && ! in_array( 'custom-fields', $args['supports'], true ) ) {
				$args['supports'][] = 'custom-fields';
			}

			return $args;
		}

Changelog

Changelog
Version Description
3.7.6 Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.