Add X meta box inputs based on form at top of meta box, how to do it right?
You could clone an existing field with jQuery and append it to the form. You’ll also have to handle cases where the number of ingredients is fewer than the number of fields, and you’ll have to use jQuery’s remove. Here’s a simple example of cloning a field: $(‘#quantity-form’).submit(function(){ // get # of fields that already … Read more