开发者

How to save a ByteArray from Flex into a FileField in Django

I have some audio data in a byte array in a Flex app that I would like to save to my model in Django. I assume I would use a FileField, but I can't seem to get it to work. (My project is set up like this.) I've tried looking at this sample code for PyAmf, but I can't quite get the two to combine.

If any开发者_运维技巧one has a bit of code to share, that would be lovely!


Django's FileFields are not blobs - they only store the path to where the data is saved on the filesystem. You will need to save the data to disk and put the path into the FileField.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜