I want square brackets to automatically appear on either side of a string of text when entered in the text field of an input form. The result needs to coincide with an onkeyup event.
Here's a snippet of code from the .php file:
$generator .= '<div class="plugin_input_wrapper">';
$generator .= 'Enter your text:';
$generator .= '<input class="text-box" type="text" id="plugin_bottom_text" maxlength="25" name="plugin_bottom_text" onkeyup="plugin_text_type();">';
$generator .= '<span class="text">  Font size:</span><input class="text-box2" type="text" id="plugin_text_font_size" maxlength="2">  px</div>';
Is this possible to do with inline Javascript?