Answer the question
In order to leave comments, you need to log in
How to add a simple visual editor to a custom post type?
in this way I throw a field for a custom record type into the
array array(
'label' => 'Description',
'desc' => '',
'id' => 'desc_product', // give an identifier.
'type' => ' textarea' // Specify the type of the field.
),
then run through foreach ($card_meta_fields as $field) {
then through switch($field['type']) {
and this is how I display the snake
case 'textarea':
echo ''.$ meta.'
'.$field['desc'].'';
break;
I need to display a simple visual editor instead of textarea, similar to this
Answer the question
In order to leave comments, you need to log in
You can connect supports, editor
wp-kama.ru/function/register_post_type#supports-array
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question