【发布时间】:2012-09-10 12:15:19
【问题描述】:
好的,例如我的 formModel 中有这个字段
RItitle = models.CharField(max_length=100)
在我的模板中:
<tr>
<th>RI Title </th><th> {{ wizard.form.RItitle }} {{ wizard.form.RItitle.errors }}</th>
</tr>
现在是 HTML:
<tr>
<th>RI Title </th><th> <input id="id_0-RItitle" type="text" name="0-RItitle" value="csss" maxlength="100"> </th>
</tr>
如何更改此字段的 html 选项?我的意思是例如 style="width:150px" 或类似的东西。我不能使用 css 示例: .输入{宽度:150px;} 因为我在这个表单中有超过 1 个输入
感谢您的帮助
【问题讨论】:
标签: html django django-forms