How can I limit the maximum total count of characters or lines in a multi-line field in a form?
Solution:
Use the following jQuery code to limit the number of lines in a multi-line field. This example sets a limit of 2 lines, but you can adjust this by changing the value of maxLines:
jQuery.noConflict();
(function($) {
$(document).ready(function() {
var maxLines = 2;
$('textarea').on('input', function() {
var textarea = $(this);
var lines = textarea.val().split('\n');
if (lines.length > maxLines) {
textarea.val(lines.slice(0, maxLines).join('\n'));
}
});
});
})(jQuery);
I don't know how to define the order of taxonomy terms to control what appears first and what appears second.
Solution:
Use the "Taxonomy Terms Order" plugin to define the order of taxonomy terms. Install and activate the plugin from https://wordpress.org/plugins/taxonomy-terms-order/, then you can drag and drop to arrange the order of taxonomy terms as desired.