Forums / Setup & design / Forum signature - ViewCacheSettings

Forum signature - ViewCacheSettings

Author Message

Radek Kuchta

Wednesday 11 July 2007 1:16:41 pm

Hi,

I'm using viewcache.ini to set up my cache behaviour.
I have a small problem with user's signature in eZ forum. When user is changing his signature (in his profile), new signature (in his forum posts) is not available as long as the view cache is clearing by another rules.
The question is, how to set up the ViewCacheSettings to take effect ?

http://ez.no/certification/verify/272582

André R.

Thursday 12 July 2007 1:33:42 am

put:

{set-block scope=root variable=cache_ttl}36000{/set-block}

in the top of override/templates/full/forum_topic.tpl
And clear the template compiled cache for this template.
This will make the content cache expire after 10 hours

PS: you should put the changed template in your own design so you don't have to redo this every time you upgrade.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Radek Kuchta

Thursday 12 July 2007 3:00:50 am

Hi André,

I'm using my own design, so I don't have to think about upgrade.

I don't want to clear cache every 10h (it's not necessary).
Is there no other way to clear that cache (by using viewcache.ini rules)?

http://ez.no/certification/verify/272582

André R.

Thursday 12 July 2007 6:04:37 am

No, and if a rule like that existed it would have to clear viewcache of all objects by owner when owner changes AND their ('all objects') parent object.
So not entirely 'light' that either.. :)

What about increasing the time to one week (604800) ?
Meaning it will refresh cache if someone posts in the thread or if the cache is more then one week old.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Radek Kuchta

Thursday 12 July 2007 7:13:47 am

Good to know, that there is no other way ;)
I'll test cache_ttl settings.

Thanks ;)

http://ez.no/certification/verify/272582

Damien Pobel

Saturday 14 July 2007 11:20:27 am

Hi,

There's probably another solution but it's a bit more complicated.
You could perhaps write a CustomEditHandler [1] and with it you can clear the cache of all objects owned by the user.

[1] http://serwatka.net/en/blog/ez_publish_3_8_new_custom_edit_handler

Damien
Planet eZ Publish.fr : http://www.planet-ezpublish.fr
Certification : http://auth.ez.no/certification/verify/372448
Publications about eZ Publish : http://pwet.fr/tags/keywords/weblog/ez_publish