The question about covers it. I'm using dreamhost, and need to utilize the st开发者_如何学Cdimagefield rather than image field so I can do this:
image3 = StdImageField(upload_to='path/to/img', size=(640, 480))
If there is a better way to do this, please let me know.
Edit: Trying it like this, everything is working with the "python manage.py shell" as you can see below:
>>> from stdimage import StdImageField
>>> image = StdImageField(upload_to='path', size=(425,325))
>>> print image
<stdimage.fields.StdImageField object at 0x762db3ac5910>
When I try to use it in my model though, I get this error on every page:
Using the URLconf defined in runningshoesreview.urls, Django tried these URL patterns, in this order:
- ^admin/(.*)
- ^reviews/
The current URL, internal_error.html, didn't match any of these.
Just copy the module contents into your project, making it a package if necessary. I put "external" modules in an external
package.
Just put the django-stdimage
folder into your project folder (it should already be a package).
精彩评论