This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // -- This method adds a field to the form: | |
| var addField = function(target){ | |
| // -- get handle on relevant fieldset container and clone it: | |
| var fieldset = target.parent().parent().find('div.item-fields').last(); | |
| var new_fieldset = fieldset.clone(); | |
| // -- Add flag to show that field was dynamically built by the front end | |
| // -- and show fieldset if the original was hidden: | |
| new_fieldset.addClass("new-dynamic-field").show(); | |
| new_fieldset.find("input.placeholder-activated").removeClass("placeholder-activated"); |
OlderNewer