For the oldforms, it should be like this: {%for field in form%} <tr> <td>{{ field.label }}</td> <td>{{ field }}{%if field.formfield.is_required %}<span class="warning">*</span>{%endif%}</td> </tr> {%endfor%}
<FONT> tag is deprecated. DO NOT use it. Use CSS. Regards, Aidas Bendoraitis aka Archatas On 6/25/07, EL AATIFI Sidi Mohamed <[EMAIL PROTECTED]> wrote: > > AnaReis wrote: > > Hi! > > I have this form where I want to put red asterisks after each required > > field, but I can't find a way to do it... > > This is my template code: > > > > <form name="form1" id="form1" action="resultadd/" method="POST" > > onSubmit="return" > > > <table> > > {%for field in form%} > > <tr><td>{{field.label}}</td><td>{{field}}{%if something_goes_here > > %}<font color="red">*</font>{%endif%}</td></tr> > > {%endfor%} > > </table> > > <input type="submit" value="Submit"> > > </form> > > > > M > You can try this > > > {% if field.required %}<font color="red">*</font> {% endif %} > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---