Hi,
I need to generate a different output based if it is a select input type
or it is a text field.
This code does not work. I am trying to do something like this:
{% for field in form %}
{% ifequal field.field.widget django.forms.widgets.Select %}
<p>{{ field.label_tag }} {{ field.errors }} {{ field }}</p>
{% else %}
<p>It is not select field</p>
{% endifequal %}
{% endfor %}
I am having hard time to do the ifequal statement. It does not get the
correct comparison. It always return true. Any idea how to fix this ?
Thanks in advance,
Leon Yeh
New Avenue Systems Inc.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---