Oops, too quick to press reply :o

On Tue, Apr 28, 2009 at 11:53 PM, Carlos A. Carnero Delgado >
destination_file = open('somewhere based on the user', 'wb+')
>  for chunk in request.FILES['audio_file'].chunks():
>      destination_file.write(chunk)
>  destination_file.close()

with this method you are manually handling the file, stepping over
Django's FileField. You should make adjustments & corrections to
account for that.

Also note that 'audio_file' is just the name of the field, it should
be named with your field name, of course. Remember also to include
request.FILES when creating your form object after a POST.

HTH,
Carlos.

--~--~---------~--~----~------------~-------~--~----~
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