Re: Django Debug Toolbar -- getting 404s for javascript file when using request.GET in SHOW_TOOLBAR_CALLBACK

2010-12-22 Thread Brian S
Thanks to kr who answered this offline. Some static files in the debug_toolbar need to be modified to include the ?debug arg. I put his suggestions into the attached patch file. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this

Django Debug Toolbar -- getting 404s for javascript file when using request.GET in SHOW_TOOLBAR_CALLBACK

2010-06-09 Thread Brian S
I am using the Django Debug Toolbar and getting some odd results with a custom SHOW_TOOLBAR_CALLBACK. I have added the debug toolbar to my INSTALLED_APPS and MIDDLEWARE_CLASSES, per the install instructions, and using the defaults, everything works fine. But instead of always showing the toolbar wh

Re: Save file object to FileField

2009-12-17 Thread Brian S
I found the answer in this discussion: http://groups.google.com/group/django-users/browse_frm/thread/184e5e09db1efce4/7816cbc650d8dc77 Pass in the filename and content to the FileField's save() method directly, rather than using the model instance's save() method. On Dec 14, 2:24 p

Save file object to FileField

2009-12-14 Thread Brian S
Could someone point me in the right direction on how to save a file object to a FileField in a model? When I try assigning the file object directly to the FileField field, I get an atrribute error: myfile = open('/home/sample.txt', 'wb') mymodelinstance.resultFile=myfile mymodelinstance.save() --