要素がdomに挿入されるたびに、入力名とIDをインクリメントするにはどうすればよいですか?
<input type="text" name="option_tree[sponsorship_section][1][image1]" id="sponsorship_section_image1_1">
これに:
<input type="text" name="option_tree[sponsorship_section][1][image2]" id="sponsorship_section_image1_2">
ありがとう