JavaScript Clone element and clear text input fields

Create a deep copy of the set of matched elements using jQuery clone method and clean the cloned input fields.

<script type="text/javascript" charset="utf-8">
$(document).ready(function(){
  var clone = $('#element').clone().find('input:text').val('').end();
});
</script>