You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 23, 2021. It is now read-only.
I find myself wanting to add short notes and instructions in meta boxes sometimes.
This could be added either as a single note at the top of the box (or one at the top and one at bottom), or by adding content to the fields array -- either as a new field type or as an option for each field.
For example - this shows 2 possible options:
$my_custom_type->add_meta_box( array(
'id' => 'type_social',
'title' => 'Social Profiles',
'instructions_pre' => 'At least one profile is required for this widget to appear in search results.',
'fields' => array (
'_twitter_username' => array( 'label'=>'Twitter Username', 'type'=>'text', 'instruction'=>'Do not include the @' ),
...
)
));
This could be HTML content, which would let you be messy if you wanted to be, but would also be the most flexible.
The text was updated successfully, but these errors were encountered:
I find myself wanting to add short notes and instructions in meta boxes sometimes.
This could be added either as a single note at the top of the box (or one at the top and one at bottom), or by adding content to the fields array -- either as a new field type or as an option for each field.
For example - this shows 2 possible options:
This could be HTML content, which would let you be messy if you wanted to be, but would also be the most flexible.
The text was updated successfully, but these errors were encountered: