Oops -- My bad.
Thank you Karen.

Regards
K

On Jan 9, 5:01 am, "Karen Tracey" <kmtra...@gmail.com> wrote:
> On Thu, Jan 8, 2009 at 3:16 PM, Kottiyath Nair <n.kottiy...@gmail.com>wrote:
>
>
>
> > Hi,
> >   I was trying out a form - with filefield. I used the option upload_to,
> > and django server erred out saying - upload_to not found.
> >   I checked django code :
> > >>> import django
> > >>> django.VERSION
> > (1, 0, 2, 'final', 0)
>
> > class FileField(Field):
> >     widget = FileInput
> >     default_error_messages = {
> >         'invalid': _(u"No file was submitted. Check the encoding type on
> > the form."),
> >         'missing': _(u"No file was submitted."),
> >         'empty': _(u"The submitted file is empty."),
> >     }
>
> >     def __init__(self, *args, **kwargs):
> >         super(FileField, self).__init__(*args, **kwargs)
>
> > --> As we can see there is no upload_to parameter in it. I am sure I am
> > missing something because upload_to seems to be the basic option as per
> > documents.
> > Can somebody help me out?
>
> upload_to is a parameter for model FileFields:
>
> http://docs.djangoproject.com/en/dev/ref/models/fields/#filefield
>
> not form FileFields:
>
> http://docs.djangoproject.com/en/dev/ref/forms/fields/#filefield
>
> Karen
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to