开发者

django STATIC_URL on production server

I want update same files from STATIC_URL. But they did't update, because browser cache statics.

Can automatically make a setting.py

STATIC_URL = '/static-%s/' % <AUTO_INCREMENT>

and regular setting i开发者_如何学编程n nginx?

Or may have a component?


Well, if these files are used for site design, i.e. they are css-files or images, you can use http://github.com/mintchaos/django_compressor or smth like this. It generates new css file and sets for all included images special token (directly in css) every time some of css files is updated.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜