Controls
Textarea
Textarea control provides a multi-line text input field, perfect for longer content like descriptions, excerpts, or any text that needs multiple paragraphs.
Control Settings
- Placeholder - Text shown when the field is empty
- Characters Limit - Maximum number of characters allowed (leave blank for no limit)
Usage Examples
Basic Output
PHP
<div class="description">
<?php echo wp_kses_post( nl2br( $attributes['control_name'] ) ); ?>
</div>
Handlebars
<div class="description">
{{control_name}}
</div>
Post Meta
Post Meta
<?php
$text = get_lzb_meta( 'control_meta_name' );
if ( $text ) {
echo '<div class="description">';
echo wp_kses_post( nl2br( $text ) );
echo '</div>';
}
?>
Use nl2br()
to convert line breaks to <br>
tags, or wpautop()
to convert them to paragraphs.