Render a Form

Report a typo

You have a form for using a promo code on the site of an online shop:

class PromoCodeForm(forms.Form):
    user = forms.CharField()
    code = forms.CharField()

Render this form to template as an unordered list.

The instance of a form is passed to the template as the promo_code_form variable.

Grader generates random restrictions for minimum and maximum length, so use form methods to complete the task.
Write a program in Python 3
template = """
<form>{% csrf_token %}
<ul> ??? </ul>
</form>
"""
___

Create a free account to access the full topic