I feel like I am missing something really obvious. I'm trying to use the WTForms template extensions with Django. I have a project on my development server which is working great (IE the extensions are working properly) but when I put it out on a test server, suddenly they are broken. Both servers have the same versions of Python, Django, WTForms installed. Settings.py is the same on both, including:
INSTALLED_APPS = (
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'wtforms.ext.django',
)
Within the template, I am doing:
{% load wtforms %}
{% autoescape off %}
<form id='returnform' action='{{form.action}}' method='POST' ENCTYPE="multipart/form-data">
And in the actual form, action is defined as:
class UserForm(wtforms.Form):
#Some fields and such here
def action(self):
return "/Admin/H/requests/"
So, on the Dev server, my page loads with the proper 'action=url' like I expect. But on my test server, it returns a page that has
'action=<bound method UserForm.action of <pulseman.admin.forms.UserForm object at 0x9c8598c>>'
Any thoughts on what I'm missing here? Thanks.