Home › Forums › General Issues › How to set a custom height for WYSIWYG? › Reply To: How to set a custom height for WYSIWYG?
Reviving this thread in case this helps – was looking for the same thing, a way to reduce the initial height of WYSIWYG fields, as it makes the admin overly bulky for small content fields that need more control than Text Area.
In digging, I found that wp-editor supports editor_height since v3.5 https://codex.wordpress.org/Function_Reference/wp_editor
Would that allow for ACF to add height as an admin option?
In the meantime, I’m using the following, but it prevents the client from being able to drag the size larger.
/*-----------------------------------------------------------------------------------*/
/* Force Height of ACF WYSIWYG Fields
/*-----------------------------------------------------------------------------------*/
add_action('admin_head', 'my_custom_wysiwyg');
function my_custom_wysiwyg() {
echo '<style>
.wp-editor-container textarea.wp-editor-area {
height: 100px !important;
}
</style>';
}
Thanks for the help,
Jonathon
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.