title: Make Django forms use comma as decimal separator
body: <p>I am writing a Django app for use in a country where they use comma as <a href="http://en.wikipedia.org/wiki/Decimal_separator" rel="nofollow noreferrer">decimal separator</a>.  I have a model that contains a <a href="http://docs.djangoproject.com/en/1.1/ref/models/fields/#decimalfield" rel="nofollow noreferrer"><code>django.db.models.DecimalField</code></a>, and I use <a href="http://docs.djangoproject.com/en/1.1/topics/forms/modelforms/" rel="nofollow noreferrer">model forms</a>.  How can I make the resulting form field render using comma and accept comma back from the user?</p>
  
  <p>Following the <a href="https://stackoverflow.com/posts/3204038/revisions">advice</a> of <a href="https://stackoverflow.com/users/298054/jweyrich">jweyrich</a>, I have upgraded my application from Django 1.1 to Django 1.2 and edited my <code>settings.py</code> to contain the following:</p>
  
  <pre><code>LANGUAGE_CODE = 'nb'
  LANGUAGES = (
    ('nb', 'Norwegian'),
  )
  USE_I18N = True
  USE_L10N = True
  DECIMAL_SEPARATOR = ','
  THOUSAND_SEPARATOR = ' '
  MIDDLEWARE_CLASSES = (
      'django.contrib.sessions.middleware.SessionMiddleware',
      'django.middleware.locale.LocaleMiddleware',
      'django.middleware.common.CommonMiddleware',
      'django.contrib.auth.middleware.AuthenticationMiddleware',
      'django.middleware.csrf.CsrfViewMiddleware',
  )
  </code></pre>
  
  <p>As far as I can see, this is all that <a href="http://docs.djangoproject.com/en/1.2/topics/i18n/localization/#format-localization" rel="nofollow noreferrer">the documentation</a> calls for.  It now works for forms if I set <code>localization=True</code> on the form field.  It works in neither <a href="http://docs.djangoproject.com/en/1.2/topics/forms/modelforms/" rel="nofollow noreferrer">model forms</a> nor <a href="http://docs.djangoproject.com/en/1.2/ref/contrib/admin/" rel="nofollow noreferrer">the admin site</a>, however.  </p>
  
  <p>I discovered a <a href="http://code.djangoproject.com/ticket/13032" rel="nofollow noreferrer">Django ticket</a> and a resulting <a href="http://code.djangoproject.com/changeset/12867" rel="nofollow noreferrer">Django changeset</a> from before the 1.2 release.  If I am understanding them correctly, it used to be the case that the widgets used format localization automatically, but after this patch localization has to be turned on explicitly by giving the <code>localization=True</code> keyword parameter to the form field.  Is there a way to make admin forms set <code>localization=True</code> on their fields?</p>