我想以相同的形式,当有情况显示1为textInput或第二为textInput这是有用的两次产生相同的字段: Django会产生:的Django:如何避免重复的HTML ID为显示在相同的形式两次领域?
<!--same form -->
<input type="radio" value="good_price"/> <!-- show good price if this is checked -->
<input type="radio" value="bad_price"/> <!-- show bad price if this is checked -->
<!--1st -->
Good price <input id="id_name"..../>
<input id="options_with_good_price"/>
<!--2nd -->
Bad Price <input id="id_name".../>
<input id="options_with_bad_price"/>
所以有重复的html ID,如何避免它? (我可没有这两个盒子与重复的ID生成的ID生存,但不是所有的人)
你是如何产生这种形式的改变
=
? –