清除Plone的CSS缓存的最佳方法是什么?

时间:2022-11-19 12:10:59

I am using Plone and CacheFu behind an Apache caching reverse proxy. Plone combines multiple CSS files into one file such as name-of-css-file-cachekey1234.css where 1234 is a random number, and it may take an hour for CSS changes made on the filesystem to show up on the site. How can I see those changes sooner without slowing down my site by enabling CSS debug mode?

我在Apache缓存反向代理后面使用Plone和CacheFu。 Plone将多个CSS文件合并到一个文件中,例如name-of-css-file-cachekey1234.css,其中1234是随机数,并且可能需要一个小时才能在文件系统上进行CSS更改以显示在网站上。通过启用CSS调试模式,如何在不降低网站速度的情况下更快地看到这些更改?

2 个解决方案

#1


Click the Save button in portal_css, and you will get a new CSS file.

单击portal_css中的“保存”按钮,您将获得一个新的CSS文件。

That's exactly why that feature exists, so that you can cache aggressively, and still get an updated CSS file when you need it.

这正是该功能存在的原因,因此您可以积极地缓存,并在需要时仍然获得更新的CSS文件。

#2


In the ZMI, if you visit portal_css (CSS Registry) and hit Save without changing any options, then a new cachekey#### appears and the new CSS rules show up on the site.

在ZMI中,如果您访问portal_css(CSS注册表)并点击保存而不更改任何选项,则会出现一个新的缓存键####,并且新的CSS规则将显示在该站点上。

#1


Click the Save button in portal_css, and you will get a new CSS file.

单击portal_css中的“保存”按钮,您将获得一个新的CSS文件。

That's exactly why that feature exists, so that you can cache aggressively, and still get an updated CSS file when you need it.

这正是该功能存在的原因,因此您可以积极地缓存,并在需要时仍然获得更新的CSS文件。

#2


In the ZMI, if you visit portal_css (CSS Registry) and hit Save without changing any options, then a new cachekey#### appears and the new CSS rules show up on the site.

在ZMI中,如果您访问portal_css(CSS注册表)并点击保存而不更改任何选项,则会出现一个新的缓存键####,并且新的CSS规则将显示在该站点上。