Changes between Version 20 and Version 21 of NewformsHOWTO


Ignore:
Timestamp:
02/27/2008 12:29:11 PM (8 years ago)
Author:
anonymous
Comment:

fix typo

Legend:

Unmodified
Added
Removed
Modified
  • NewformsHOWTO

    v20 v21  
    105105#!python
    106106    def formfield_for_dbfield(self, db_field, **kwargs):
    107         field = super(MyModel, self).formfield_for_db_field(db_field, **kwargs) # Get the default field
     107        field = super(MyModel, self).formfield_for_dbfield(db_field, **kwargs) # Get the default field
    108108        if db_field.name == "the_field_I_want_to_change": # Check if it's the one you want
    109109            field.widget.attrs['class'] = "my_new_class" # Poke in the new
Back to Top